* [PATCHv2 06/10] ARM: SMDK64XX: Enable AC97 device
@ 2010-01-27 5:59 jassisinghbrar at gmail.com
2010-01-27 10:45 ` Mark Brown
2010-01-28 3:41 ` Ben Dooks
0 siblings, 2 replies; 5+ messages in thread
From: jassisinghbrar at gmail.com @ 2010-01-27 5:59 UTC (permalink / raw)
To: linux-arm-kernel
From: Jassi Brar <jassi.brar@samsung.com>
Add AC97 controller to platform devices and initialize the AC97 gpios.
Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
---
arch/arm/mach-s3c6410/mach-smdk6410.c | 9 ++++++++-
1 files changed, 8 insertions(+), 1 deletions(-)
diff --git a/arch/arm/mach-s3c6410/mach-smdk6410.c b/arch/arm/mach-s3c6410/mach-smdk6410.c
index eba345f..259ebbb 100644
--- a/arch/arm/mach-s3c6410/mach-smdk6410.c
+++ b/arch/arm/mach-s3c6410/mach-smdk6410.c
@@ -55,6 +55,7 @@
#include <plat/gpio-cfg.h>
#include <plat/s3c6410.h>
+#include <plat/audio.h>
#include <plat/clock.h>
#include <plat/devs.h>
#include <plat/cpu.h>
@@ -253,7 +254,9 @@ static struct platform_device *smdk6410_devices[] __initdata = {
&smdk6410_b_pwr_5v,
#endif
&smdk6410_lcd_powerdev,
-
+#ifdef CONFIG_SND_SOC_SMDK_WM9713
+ &s3c64xx_device_ac97,
+#endif
&smdk6410_smsc911x,
};
@@ -475,6 +478,10 @@ static void __init smdk6410_machine_init(void)
i2c_register_board_info(0, i2c_devs0, ARRAY_SIZE(i2c_devs0));
i2c_register_board_info(1, i2c_devs1, ARRAY_SIZE(i2c_devs1));
+#ifdef CONFIG_SND_SOC_SMDK_WM9713
+ s3c64xx_ac97_setup_gpio(S3C64XX_AC97_GPD);
+#endif
+
platform_add_devices(smdk6410_devices, ARRAY_SIZE(smdk6410_devices));
}
--
1.6.2.5
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCHv2 06/10] ARM: SMDK64XX: Enable AC97 device
2010-01-27 5:59 [PATCHv2 06/10] ARM: SMDK64XX: Enable AC97 device jassisinghbrar at gmail.com
@ 2010-01-27 10:45 ` Mark Brown
2010-01-28 3:41 ` Ben Dooks
1 sibling, 0 replies; 5+ messages in thread
From: Mark Brown @ 2010-01-27 10:45 UTC (permalink / raw)
To: linux-arm-kernel
On Wed, Jan 27, 2010 at 02:59:29PM +0900, jassisinghbrar at gmail.com wrote:
> From: Jassi Brar <jassi.brar@samsung.com>
>
> Add AC97 controller to platform devices and initialize the AC97 gpios.
>
> Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCHv2 06/10] ARM: SMDK64XX: Enable AC97 device
2010-01-27 5:59 [PATCHv2 06/10] ARM: SMDK64XX: Enable AC97 device jassisinghbrar at gmail.com
2010-01-27 10:45 ` Mark Brown
@ 2010-01-28 3:41 ` Ben Dooks
2010-01-28 4:08 ` jassi brar
1 sibling, 1 reply; 5+ messages in thread
From: Ben Dooks @ 2010-01-28 3:41 UTC (permalink / raw)
To: linux-arm-kernel
On Wed, Jan 27, 2010 at 02:59:29PM +0900, jassisinghbrar at gmail.com wrote:
> From: Jassi Brar <jassi.brar@samsung.com>
>
> Add AC97 controller to platform devices and initialize the AC97 gpios.
I'd much rather see platform devices always added unless there is a really
good reason not to. People can build things as modules and this means you
end up having to rebuild the core kernel as well as the module if you want
to change.
> Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
> ---
> arch/arm/mach-s3c6410/mach-smdk6410.c | 9 ++++++++-
> 1 files changed, 8 insertions(+), 1 deletions(-)
>
> diff --git a/arch/arm/mach-s3c6410/mach-smdk6410.c b/arch/arm/mach-s3c6410/mach-smdk6410.c
> index eba345f..259ebbb 100644
> --- a/arch/arm/mach-s3c6410/mach-smdk6410.c
> +++ b/arch/arm/mach-s3c6410/mach-smdk6410.c
> @@ -55,6 +55,7 @@
> #include <plat/gpio-cfg.h>
>
> #include <plat/s3c6410.h>
> +#include <plat/audio.h>
> #include <plat/clock.h>
> #include <plat/devs.h>
> #include <plat/cpu.h>
> @@ -253,7 +254,9 @@ static struct platform_device *smdk6410_devices[] __initdata = {
> &smdk6410_b_pwr_5v,
> #endif
> &smdk6410_lcd_powerdev,
> -
> +#ifdef CONFIG_SND_SOC_SMDK_WM9713
> + &s3c64xx_device_ac97,
> +#endif
> &smdk6410_smsc911x,
> };
>
> @@ -475,6 +478,10 @@ static void __init smdk6410_machine_init(void)
> i2c_register_board_info(0, i2c_devs0, ARRAY_SIZE(i2c_devs0));
> i2c_register_board_info(1, i2c_devs1, ARRAY_SIZE(i2c_devs1));
>
> +#ifdef CONFIG_SND_SOC_SMDK_WM9713
> + s3c64xx_ac97_setup_gpio(S3C64XX_AC97_GPD);
> +#endif
> +
> platform_add_devices(smdk6410_devices, ARRAY_SIZE(smdk6410_devices));
> }
>
> --
> 1.6.2.5
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
> the body of a message to majordomo at vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
--
--
Ben
Q: What's a light-year?
A: One-third less calories than a regular year.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCHv2 06/10] ARM: SMDK64XX: Enable AC97 device
2010-01-28 3:41 ` Ben Dooks
@ 2010-01-28 4:08 ` jassi brar
2010-01-28 5:31 ` jassi brar
0 siblings, 1 reply; 5+ messages in thread
From: jassi brar @ 2010-01-28 4:08 UTC (permalink / raw)
To: linux-arm-kernel
On Thu, Jan 28, 2010 at 12:41 PM, Ben Dooks <ben@trinity.fluff.org> wrote:
> On Wed, Jan 27, 2010 at 02:59:29PM +0900, jassisinghbrar at gmail.com wrote:
>> From: Jassi Brar <jassi.brar@samsung.com>
>>
>> Add AC97 controller to platform devices and initialize the AC97 gpios.
>
> I'd much rather see platform devices always added unless there is a really
> good reason not to. People can build things as modules and this means you
> end up having to rebuild the core kernel as well as the module if you want
> to change.
Yes, sounds good to me. I will revise this patch accordingly.
Thanks
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCHv2 06/10] ARM: SMDK64XX: Enable AC97 device
2010-01-28 4:08 ` jassi brar
@ 2010-01-28 5:31 ` jassi brar
0 siblings, 0 replies; 5+ messages in thread
From: jassi brar @ 2010-01-28 5:31 UTC (permalink / raw)
To: linux-arm-kernel
On Thu, Jan 28, 2010 at 1:08 PM, jassi brar <jassisinghbrar@gmail.com> wrote:
> On Thu, Jan 28, 2010 at 12:41 PM, Ben Dooks <ben@trinity.fluff.org> wrote:
>> On Wed, Jan 27, 2010 at 02:59:29PM +0900, jassisinghbrar at gmail.com wrote:
>>> From: Jassi Brar <jassi.brar@samsung.com>
>>>
>>> Add AC97 controller to platform devices and initialize the AC97 gpios.
>>
>> I'd much rather see platform devices always added unless there is a really
>> good reason not to. People can build things as modules and this means you
>> end up having to rebuild the core kernel as well as the module if you want
>> to change.
> Yes, sounds good to me. I will revise this patch accordingly.
> Thanks
s3c64xx_device_ac97 device is exported from dev-audio.c
which is compiled only if CONFIG_SND_S3C24XX_SOC is defined.
So, If we unconditionally add the platform device, it will give error in case
the user didn't select Samsung ASoC option.
So, I guess i should make it conditional on CONFIG_SND_S3C24XX_SOC
rather than CONFIG_SND_SOC_SMDK_WM9713
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-01-28 5:31 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-01-27 5:59 [PATCHv2 06/10] ARM: SMDK64XX: Enable AC97 device jassisinghbrar at gmail.com
2010-01-27 10:45 ` Mark Brown
2010-01-28 3:41 ` Ben Dooks
2010-01-28 4:08 ` jassi brar
2010-01-28 5:31 ` jassi brar
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).