[coreboot] pc speaker and cs5536
Nikolay Petukhov
nikolaypetukhov at gmail.com
Thu Mar 13 07:24:02 CET 2008
OK, then it is easier to include in a mainboard.c.
2008/3/11, Jordan Crouse <jordan.crouse at amd.com>:
> On 11/03/08 15:53 +0500, Nikolay Petukhov wrote:
> > Hi, all.
> >
> > I have PCISA-LX-800 board (AMD LX800 + CS5536)
> > http://www.ieiworld.com/en/product_IPC.asp?model=PCISA-LX.
> >
> > With coreboot bios pc speaker not work on Linux.
> > But with vendor BIOS pc speaker work on Linux OK.
> >
> > The CS5536 datasheet say:
> > Legacy PC/AT Speaker Beep is only available when GPIO1 is programmed
> > to OUT_AUX1.
> > The coreboot not enable pc speaker output on cs5536.
> >
> > This patch enable pc speaker output on cs5536 based devices.
> >
> > Signed-off-by: Nikolay Petukhov <nikolay.petukhov at gmail.com>
>
>
> comments below.
>
> > --
> > Nikolay
>
> > diff -Nru coreboot-v2-3132/src/southbridge/amd/cs5536/cs5536_early_setup.c coreboot-v2-3132-beep/src/southbridge/amd/cs5536/cs5536_early_setup.c
> > --- coreboot-v2-3132/src/southbridge/amd/cs5536/cs5536_early_setup.c 2008-01-18 15:35:56.000000000 +0500
> > +++ coreboot-v2-3132-beep/src/southbridge/amd/cs5536/cs5536_early_setup.c 2008-03-11 10:36:42.000000000 +0500
> > @@ -123,6 +123,15 @@
> > outl(val, GPIO_IO_BASE + GPIOL_INPUT_ENABLE);
> > }
>
> > +static void cs5536_setup_beep(void)
> > +{
> > + /* GPIO1 - BEEP */
> > + /* Set: Output Enable (0x4) */
> > + outl(GPIOL_1_SET, GPIO_IO_BASE + GPIOL_OUTPUT_ENABLE);
> > + /* Set: OUTAUX1 Select (0x10) */
> > + outl(GPIOL_1_SET, GPIO_IO_BASE + GPIOL_OUT_AUX1_SELECT);
> > +}
>
> I think we should wrap this with a config option. Lots of platform designs
> these days are omitting the legacy speaker hardware and reclaiming
> GPIO1.
>
> > static void cs5536_disable_internal_uart(void)
> > {
> > msr_t msr;
> > @@ -221,4 +230,5 @@
> > cs5536_enable_smbus();
> > //print_debug("Setup power button\r\n");
> > cs5536_setup_power_button();
> > + cs5536_setup_beep();
> > }
>
> Jordan
>
>
> --
> Jordan Crouse
> Systems Software Development Engineer
> Advanced Micro Devices, Inc.
>
>
--
Nikolay
More information about the coreboot
mailing list