Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1248486 > unrolled thread
| Started by | Borislav Petkov <bp@alien8.de> |
|---|---|
| First post | 2015-10-16 11:00 +0200 |
| Last post | 2015-10-17 18:40 +0200 |
| Articles | 4 — 3 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH] input: i8042: add quirk to implement i8042 detect for AMD Borislav Petkov <bp@alien8.de> - 2015-10-16 11:00 +0200
Re: [PATCH] input: i8042: add quirk to implement i8042 detect for AMD Wan ZongShun <mcuos.com@gmail.com> - 2015-10-16 11:40 +0200
Re: [PATCH] input: i8042: add quirk to implement i8042 detect for AMD Borislav Petkov <bp@alien8.de> - 2015-10-16 12:30 +0200
Re: [PATCH] input: i8042: add quirk to implement i8042 detect for AMD Dmitry Torokhov <dmitry.torokhov@gmail.com> - 2015-10-17 18:40 +0200
| From | Borislav Petkov <bp@alien8.de> |
|---|---|
| Date | 2015-10-16 11:00 +0200 |
| Subject | Re: [PATCH] input: i8042: add quirk to implement i8042 detect for AMD |
| Message-ID | <qk91N-1e0-17@gated-at.bofh.it> |
On Fri, Oct 16, 2015 at 09:27:00AM -0400, Vincent Wan wrote:
> Detecting platform supports i8042 or not, AMD resorted to
> BIOS's FADT i8042 flag.
>
> Signed-off-by: Vincent Wan <Vincent.Wan@amd.com>
> ---
> drivers/input/serio/i8042-x86ia64io.h | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/drivers/input/serio/i8042-x86ia64io.h b/drivers/input/serio/i8042-x86ia64io.h
> index c115565..bf3a605 100644
> --- a/drivers/input/serio/i8042-x86ia64io.h
> +++ b/drivers/input/serio/i8042-x86ia64io.h
> @@ -9,6 +9,7 @@
>
> #ifdef CONFIG_X86
> #include <asm/x86_init.h>
> +#include <linux/acpi.h>
> #endif
>
> /*
> @@ -1047,6 +1048,11 @@ static int __init i8042_platform_init(void)
> /* Just return if pre-detection shows no i8042 controller exist */
> if (!x86_platform.i8042_detect())
> return -ENODEV;
> +
> + if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD) {
Why the vendor check if you're accessing a bit defined in the ACPI spec?
> + if (!(acpi_gbl_FADT.boot_flags & ACPI_FADT_8042))
> + return -ENODEV;
> + }
--
Regards/Gruss,
Boris.
ECO tip #101: Trim your mails when you reply.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [next] | [standalone]
| From | Wan ZongShun <mcuos.com@gmail.com> |
|---|---|
| Date | 2015-10-16 11:40 +0200 |
| Message-ID | <qk9Eu-2dv-11@gated-at.bofh.it> |
| In reply to | #1248486 |
2015-10-16 16:58 GMT+08:00 Borislav Petkov <bp@alien8.de>:
> On Fri, Oct 16, 2015 at 09:27:00AM -0400, Vincent Wan wrote:
>> Detecting platform supports i8042 or not, AMD resorted to
>> BIOS's FADT i8042 flag.
>>
>> Signed-off-by: Vincent Wan <Vincent.Wan@amd.com>
>> ---
>> drivers/input/serio/i8042-x86ia64io.h | 6 ++++++
>> 1 file changed, 6 insertions(+)
>> /*
>> @@ -1047,6 +1048,11 @@ static int __init i8042_platform_init(void)
>> /* Just return if pre-detection shows no i8042 controller exist */
>> if (!x86_platform.i8042_detect())
>> return -ENODEV;
>> +
>> + if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD) {
>
> Why the vendor check if you're accessing a bit defined in the ACPI spec?
From intel's 'x86_platform.i8042_detect' implementation, I doubt if
their BIOS is providing this i8024 flag.
So I have to implement my codes carefully.
>
>> + if (!(acpi_gbl_FADT.boot_flags & ACPI_FADT_8042))
>> + return -ENODEV;
>> + }
>
> --
> Regards/Gruss,
> Boris.
>
> ECO tip #101: Trim your mails when you reply.
--
---
Vincent Wan(Zongshun)
www.mcuos.com
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | Borislav Petkov <bp@alien8.de> |
|---|---|
| Date | 2015-10-16 12:30 +0200 |
| Message-ID | <qkaqS-3p4-35@gated-at.bofh.it> |
| In reply to | #1248519 |
On Fri, Oct 16, 2015 at 05:35:40PM +0800, Wan ZongShun wrote:
> 2015-10-16 16:58 GMT+08:00 Borislav Petkov <bp@alien8.de>:
> > On Fri, Oct 16, 2015 at 09:27:00AM -0400, Vincent Wan wrote:
> >> Detecting platform supports i8042 or not, AMD resorted to
> >> BIOS's FADT i8042 flag.
> >>
> >> Signed-off-by: Vincent Wan <Vincent.Wan@amd.com>
> >> ---
> >> drivers/input/serio/i8042-x86ia64io.h | 6 ++++++
> >> 1 file changed, 6 insertions(+)
>
> >> /*
> >> @@ -1047,6 +1048,11 @@ static int __init i8042_platform_init(void)
> >> /* Just return if pre-detection shows no i8042 controller exist */
> >> if (!x86_platform.i8042_detect())
> >> return -ENODEV;
> >> +
> >> + if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD) {
> >
> > Why the vendor check if you're accessing a bit defined in the ACPI spec?
>
> From intel's 'x86_platform.i8042_detect' implementation, I doubt if
> their BIOS is providing this i8024 flag.
Why would you doubt that - it is at least in ACPI v4, if not earlier. If
you still doubt that, go and check it or ask Intel people.
> So I have to implement my codes carefully.
What are you people talking about?!
It is in the ACPI spec - this bit is either set or not. If it is not
set, then that's a problem. But then it is the problem of this one BIOS.
Vendor checks have nothing to do in vendor-agnostic code.
Besides, there's intel_mid_i8042_detect() which is platform-specific and
Intel can supply a specific ->detect() function if, in the very distant
chance, they don't implement that bit.
Still no need for a vendor check!
--
Regards/Gruss,
Boris.
ECO tip #101: Trim your mails when you reply.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [next] | [standalone]
| From | Dmitry Torokhov <dmitry.torokhov@gmail.com> |
|---|---|
| Date | 2015-10-17 18:40 +0200 |
| Message-ID | <qkCGw-31E-33@gated-at.bofh.it> |
| In reply to | #1248562 |
On Fri, Oct 16, 2015 at 12:21:55PM +0200, Borislav Petkov wrote:
> On Fri, Oct 16, 2015 at 05:35:40PM +0800, Wan ZongShun wrote:
> > 2015-10-16 16:58 GMT+08:00 Borislav Petkov <bp@alien8.de>:
> > > On Fri, Oct 16, 2015 at 09:27:00AM -0400, Vincent Wan wrote:
> > >> Detecting platform supports i8042 or not, AMD resorted to
> > >> BIOS's FADT i8042 flag.
> > >>
> > >> Signed-off-by: Vincent Wan <Vincent.Wan@amd.com>
> > >> ---
> > >> drivers/input/serio/i8042-x86ia64io.h | 6 ++++++
> > >> 1 file changed, 6 insertions(+)
> >
> > >> /*
> > >> @@ -1047,6 +1048,11 @@ static int __init i8042_platform_init(void)
> > >> /* Just return if pre-detection shows no i8042 controller exist */
> > >> if (!x86_platform.i8042_detect())
> > >> return -ENODEV;
> > >> +
> > >> + if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD) {
> > >
> > > Why the vendor check if you're accessing a bit defined in the ACPI spec?
> >
> > From intel's 'x86_platform.i8042_detect' implementation, I doubt if
> > their BIOS is providing this i8024 flag.
>
> Why would you doubt that - it is at least in ACPI v4, if not earlier. If
> you still doubt that, go and check it or ask Intel people.
>
> > So I have to implement my codes carefully.
>
> What are you people talking about?!
>
> It is in the ACPI spec - this bit is either set or not. If it is not
Well, the fact that is is in a spec does not mean that vendors follow
it (and BTW I do not think that AMD as a CPU vendor can vouch for a
random notebook or desktop vendor that acquired and then hacked on some
version of some BIOS from some BIOS vendor so I agree that this check is
a no-go).
Historically we did not trust BIOS data with regard to i8042 on x86.
Maybe we should now using certain date cutoff (anything manufactured
past 201[2345?]).
Does Windows respect this flag? If it does then we could also trust it,
and not only on AMD but for all x86 CPUs.
Thanks.
--
Dmitry
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web