From 75c83870e51e6bc48a83114c64177432d3204b1f Mon Sep 17 00:00:00 2001 From: Vladimir Serbinenko Date: Fri, 5 Sep 2014 01:01:31 +0200 Subject: azalia: Shrink boilerplate Change-Id: Ib3e09644c0ee71aacb067adaa85653d151b52078 Signed-off-by: Vladimir Serbinenko Reviewed-on: http://review.coreboot.org/6840 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer Reviewed-by: Edward O'Callaghan --- src/include/device/azalia_device.h | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) (limited to 'src/include') diff --git a/src/include/device/azalia_device.h b/src/include/device/azalia_device.h index 4940cd238d..0f477a357a 100644 --- a/src/include/device/azalia_device.h +++ b/src/include/device/azalia_device.h @@ -20,15 +20,26 @@ #ifndef DEVICE_AZALIA_H #define DEVICE_AZALIA_H +#include +#include +#include +#include +#include +#include +#include + #include void azalia_audio_init(struct device *dev); extern struct device_operations default_azalia_audio_ops; -extern const u32 *cim_verb_data; -extern u32 cim_verb_data_size; -extern const u32 *pc_beep_verbs; -extern u32 pc_beep_verbs_size; +extern const u32 cim_verb_data[]; +extern const u32 cim_verb_data_size; +extern const u32 pc_beep_verbs[]; +extern const u32 pc_beep_verbs_size; + +#define AZALIA_ARRAY_SIZES const u32 pc_beep_verbs_size = ARRAY_SIZE(pc_beep_verbs); \ + const u32 cim_verb_data_size = sizeof(cim_verb_data) #define AZALIA_PIN_CFG(codec, pin, val) \ ((codec) << 28) | ((pin) << 20) | ( 0x71c << 8) | ((val) & 0xff), \ -- cgit v1.2.3