[coreboot] W83977EF vs. ASUS P2B-L vs. PS/2 keyboard - patch included

Keith Hui buurin at gmail.com
Wed Mar 24 00:35:30 CET 2010


> ------------------------------
>
> Message: 3
> Date: Tue, 23 Mar 2010 08:02:25 -0700
> From: ron minnich <rminnich at gmail.com>
> To: Mark Marshall <mark.marshall at csr.com>
> Cc: coreboot at coreboot.org
> Subject: Re: [coreboot] W83977EF vs. ASUS P2B-L vs. PS/2 keyboard
> Message-ID:
>        <13426df11003230802g244d3d3v6cfb5e21550334fa at mail.gmail.com>
> Content-Type: text/plain; charset=ISO-8859-1
>
> On Mon, Mar 22, 2010 at 6:38 AM, Mark Marshall <mark.marshall at csr.com> wrote:
>
>>
>> Change
>>
>> 152 ? ? void pnp_enable(device_t dev)
>> 153 ? ? {
>> 154 ? ? ? ? ? ? if (!dev->enabled) {
>> 155 ? ? ? ? ? ? ? ? ? ? pnp_set_logical_device(dev);
>> 156 ? ? ? ? ? ? ? ? ? ? pnp_set_enable(dev, 0);
>> 157 ? ? ? ? ? ? }
>> 158 ? ? }
>
> the pnp code was never quite finished in some ways ...
>  void pnp_enable(device_t dev)
> void pnp_enable(device_t dev
>  {
>> 154             if (!dev->enabled) {
>> 155                     pnp_set_logical_device(dev);
>> 156                     pnp_set_enable(dev, 0);
>> 157             } else {
>> 155                     pnp_set_logical_device(dev);
>> 156                     pnp_set_enable(dev, 1);
> }
>
>
> sorry for formatting, I'm where it's not easy to do.
>
> So if it's not enabled, disable it; else enable it.
>
> Others can comment on whether this is going to be a bad idea.
>
> ron

Mark's suggestion is too good to not make a patch out of.

Ron, turns out your extra branching is not necessary. pnp_set_enable()
only care if that argument is zero or not; it doesn't have to be 1.

The attached patch fixes this PnP device enabling, and solves the long
standing issue of PS/2 keyboard (and mouse - I just tried with this
patch and my mouse works! :-D ) not working with the entire P2B family
of mainboards, and possibly all boards using the W83977TF/EF super I/O
chips.

Cheers. And many thanks to Mark. Hope this is OK with you - me making
a patch out of your suggestion.

Signed-off-by: Keith Hui <buurin at gmail.com>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pnp.patch
Type: application/octet-stream
Size: 443 bytes
Desc: not available
URL: <http://www.coreboot.org/pipermail/coreboot/attachments/20100323/d3f139e5/attachment.obj>


More information about the coreboot mailing list