diff options
author | Takashi Iwai <tiwai@suse.de> | 2014-11-25 05:28:07 -0500 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2014-11-28 02:47:28 -0500 |
commit | 37e661ee10c6d0d1310c62b3d29ae9a63073ac5d (patch) | |
tree | 7e4d170a18685cc15dc8a7942dcb0fd00bb3a905 /sound/pci/hda/hda_priv.h | |
parent | acf403ecc4155153e5e2c1640be90fc166e56ba7 (diff) |
ALSA: hda - Add AZX_DCAPS_SNOOP_OFF (and refactor snoop setup)
Add a new driver_caps bit, AZX_DCAPS_SNOOP_OFF, to set the snoop off
as default. This new bit is used for the checks in
azx_check_snoop_available(). Most of case-switches are replaced with
the new dcaps in each entry.
While working on it, for avoiding to spend more bits, combine three
bits AZX_DCAPS_SNOOP_SCH, AZX_DCAPS_SNOOP_ATI and
AZX_DCAPS_SNOOP_NVIDIA bits into a flat type of two bits. This
reduces the bits usages, and assign AZX_DCAPS_OFF to this empty bit
now.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/hda/hda_priv.h')
-rw-r--r-- | sound/pci/hda/hda_priv.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/sound/pci/hda/hda_priv.h b/sound/pci/hda/hda_priv.h index 949cd437eeb2..602536c2147d 100644 --- a/sound/pci/hda/hda_priv.h +++ b/sound/pci/hda/hda_priv.h | |||
@@ -152,9 +152,8 @@ enum { SDI0, SDI1, SDI2, SDI3, SDO0, SDO1, SDO2, SDO3 }; | |||
152 | /* bits 0-7 are used for indicating driver type */ | 152 | /* bits 0-7 are used for indicating driver type */ |
153 | #define AZX_DCAPS_NO_TCSEL (1 << 8) /* No Intel TCSEL bit */ | 153 | #define AZX_DCAPS_NO_TCSEL (1 << 8) /* No Intel TCSEL bit */ |
154 | #define AZX_DCAPS_NO_MSI (1 << 9) /* No MSI support */ | 154 | #define AZX_DCAPS_NO_MSI (1 << 9) /* No MSI support */ |
155 | #define AZX_DCAPS_ATI_SNOOP (1 << 10) /* ATI snoop enable */ | 155 | #define AZX_DCAPS_SNOOP_MASK (3 << 10) /* snoop type mask */ |
156 | #define AZX_DCAPS_NVIDIA_SNOOP (1 << 11) /* Nvidia snoop enable */ | 156 | #define AZX_DCAPS_SNOOP_OFF (1 << 12) /* snoop default off */ |
157 | #define AZX_DCAPS_SCH_SNOOP (1 << 12) /* SCH/PCH snoop enable */ | ||
158 | #define AZX_DCAPS_RIRB_DELAY (1 << 13) /* Long delay in read loop */ | 157 | #define AZX_DCAPS_RIRB_DELAY (1 << 13) /* Long delay in read loop */ |
159 | #define AZX_DCAPS_RIRB_PRE_DELAY (1 << 14) /* Put a delay before read */ | 158 | #define AZX_DCAPS_RIRB_PRE_DELAY (1 << 14) /* Put a delay before read */ |
160 | #define AZX_DCAPS_CTX_WORKAROUND (1 << 15) /* X-Fi workaround */ | 159 | #define AZX_DCAPS_CTX_WORKAROUND (1 << 15) /* X-Fi workaround */ |
@@ -172,6 +171,13 @@ enum { SDI0, SDI1, SDI2, SDI3, SDO0, SDO1, SDO2, SDO3 }; | |||
172 | #define AZX_DCAPS_I915_POWERWELL (1 << 27) /* HSW i915 powerwell support */ | 171 | #define AZX_DCAPS_I915_POWERWELL (1 << 27) /* HSW i915 powerwell support */ |
173 | #define AZX_DCAPS_CORBRP_SELF_CLEAR (1 << 28) /* CORBRP clears itself after reset */ | 172 | #define AZX_DCAPS_CORBRP_SELF_CLEAR (1 << 28) /* CORBRP clears itself after reset */ |
174 | 173 | ||
174 | enum { | ||
175 | AZX_SNOOP_TYPE_NONE , | ||
176 | AZX_SNOOP_TYPE_SCH, | ||
177 | AZX_SNOOP_TYPE_ATI, | ||
178 | AZX_SNOOP_TYPE_NVIDIA, | ||
179 | }; | ||
180 | |||
175 | /* HD Audio class code */ | 181 | /* HD Audio class code */ |
176 | #define PCI_CLASS_MULTIMEDIA_HD_AUDIO 0x0403 | 182 | #define PCI_CLASS_MULTIMEDIA_HD_AUDIO 0x0403 |
177 | 183 | ||