/* SPDX-License-Identifier: GPL-2.0-only */

#include <device/azalia_device.h>

static const u32 realtek_alc1150_verbs[] = {
	AZALIA_SUBVENDOR(0, 0x1043857e),
	AZALIA_PIN_CFG(0, 0x11, AZALIA_PIN_DESC(
		AZALIA_INTEGRATED,
		AZALIA_ATAPI,
		AZALIA_SPDIF_OUT,
		AZALIA_ATAPI_INTERNAL,
		AZALIA_COLOR_UNKNOWN,
		AZALIA_NO_JACK_PRESENCE_DETECT,
		3, 0
	)),
	AZALIA_PIN_CFG(0, 0x14, AZALIA_PIN_DESC(
		AZALIA_JACK,
		AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_REAR,
		AZALIA_LINE_OUT,
		AZALIA_STEREO_MONO_1_8,
		AZALIA_GREEN,
		AZALIA_JACK_PRESENCE_DETECT,
		1, 0
	)),
	AZALIA_PIN_CFG(0, 0x15, AZALIA_PIN_DESC(
		AZALIA_JACK,
		AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_REAR,
		AZALIA_LINE_OUT,
		AZALIA_STEREO_MONO_1_8,
		AZALIA_BLACK,
		AZALIA_JACK_PRESENCE_DETECT,
		1, 2
	)),
	AZALIA_PIN_CFG(0, 0x16, AZALIA_PIN_DESC(
		AZALIA_JACK,
		AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_REAR,
		AZALIA_LINE_OUT,
		AZALIA_STEREO_MONO_1_8,
		AZALIA_ORANGE,
		AZALIA_JACK_PRESENCE_DETECT,
		1, 1
	)),
	AZALIA_PIN_CFG(0, 0x17, AZALIA_PIN_DESC(
		AZALIA_JACK,
		AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_REAR,
		AZALIA_LINE_OUT,
		AZALIA_STEREO_MONO_1_8,
		AZALIA_GREY,
		AZALIA_JACK_PRESENCE_DETECT,
		1, 4
	)),
	AZALIA_PIN_CFG(0, 0x18, AZALIA_PIN_DESC(
		AZALIA_JACK,
		AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_REAR,
		AZALIA_MIC_IN,
		AZALIA_STEREO_MONO_1_8,
		AZALIA_PINK,
		AZALIA_JACK_PRESENCE_DETECT,
		5, 0
	)),
	AZALIA_PIN_CFG(0, 0x19, AZALIA_PIN_DESC(
		AZALIA_JACK,
		AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_FRONT,
		AZALIA_MIC_IN,
		AZALIA_STEREO_MONO_1_8,
		AZALIA_PINK,
		AZALIA_JACK_PRESENCE_DETECT,
		6, 0
	)),
	AZALIA_PIN_CFG(0, 0x1a, AZALIA_PIN_DESC(
		AZALIA_JACK,
		AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_REAR,
		AZALIA_LINE_IN,
		AZALIA_STEREO_MONO_1_8,
		AZALIA_BLUE,
		AZALIA_JACK_PRESENCE_DETECT,
		5, 15
	)),
	AZALIA_PIN_CFG(0, 0x1b, AZALIA_PIN_DESC(
		AZALIA_JACK,
		AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_FRONT,
		AZALIA_HP_OUT,
		AZALIA_STEREO_MONO_1_8,
		AZALIA_GREEN,
		AZALIA_JACK_PRESENCE_DETECT,
		2, 0
	)),
	AZALIA_PIN_CFG(0, 0x1e, AZALIA_PIN_DESC(
		AZALIA_JACK,
		AZALIA_EXTERNAL_PRIMARY_CHASSIS | AZALIA_REAR,
		AZALIA_SPDIF_OUT,
		AZALIA_OPTICAL,
		AZALIA_ORANGE,
		AZALIA_NO_JACK_PRESENCE_DETECT,
		4, 0
	)),
};

const u32 pc_beep_verbs[0] = {};

struct azalia_codec mainboard_azalia_codecs[] = {
	{
		.name         = "Realtek ALC1150",
		.vendor_id    = 0x10ec0900,
		.subsystem_id = 0x1043857e,
		.address      = 0,
		.verbs        = realtek_alc1150_verbs,
		.verb_count   = ARRAY_SIZE(realtek_alc1150_verbs),
	},
	{ /* terminator */ }
};

AZALIA_ARRAY_SIZES;
