All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: [PATCH] x86/reboot: Add Dell Optiplex 7450 AIO reboot quirk
       [not found] <1468490756-28834-1-git-send-email-alex.hung@canonical.com>
@ 2016-07-14 12:58 ` Ingo Molnar
  2016-07-14 13:16   ` Alex Hung
  0 siblings, 1 reply; 3+ messages in thread
From: Ingo Molnar @ 2016-07-14 12:58 UTC (permalink / raw)
  To: Alex Hung; +Cc: tglx, mingo, hpa, x86, linux-kernel


* Alex Hung <alex.hung@canonical.com> wrote:

> Dell Optiplex 7450 AIO works with BOOT_ACPI; however, the quirk for
> "OptiPlex 745" changes its boot method to BOOT_BIOS and causes 7450 AIO
> hangs when rebooting; as a result, 7450 AIO is appended to overwrite
> BOOT_BIOS by BOOT_ACPI in order not to break the original 745 series
> 
> Signed-off-by: Alex Hung <alex.hung@canonical.com>
> ---
>  arch/x86/kernel/reboot.c | 21 +++++++++++++++++++++
>  1 file changed, 21 insertions(+)
> 
> diff --git a/arch/x86/kernel/reboot.c b/arch/x86/kernel/reboot.c
> index b7e1d5f..b404d05 100644
> --- a/arch/x86/kernel/reboot.c
> +++ b/arch/x86/kernel/reboot.c
> @@ -55,6 +55,19 @@ bool port_cf9_safe = false;
>   */
>  
>  /*
> + * Some machines require the "reboot=a" commandline options
> + */
> +static int __init set_acpi_reboot(const struct dmi_system_id *d)
> +{
> +	if (reboot_type != BOOT_ACPI) {
> +		reboot_type = BOOT_ACPI;
> +		pr_info("%s series board detected. Selecting %s-method for reboots.\n",
> +			d->ident, "ACPI");
> +	}
> +	return 0;
> +}
> +
> +/*
>   * Some machines require the "reboot=b" or "reboot=k"  commandline options,
>   * this quirk makes that automatic.
>   */
> @@ -395,6 +408,14 @@ static struct dmi_system_id __initdata reboot_dmi_table[] = {
>  			DMI_MATCH(DMI_PRODUCT_NAME, "Dell XPS710"),
>  		},
>  	},
> +	{	/* Handle problems with rebooting on Dell Optiplex 7450 AIO */
> +		.callback = set_acpi_reboot,
> +		.ident = "Dell OptiPlex 7450 AIO",
> +		.matches = {
> +			DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
> +			DMI_MATCH(DMI_PRODUCT_NAME, "OptiPlex 7450 AIO"),
> +		},
> +	},

I think it would be better to limit the original "Dell Optiplex 745" quirk to that 
machine alone instead of quirking the quirk on one of the (known) newer models 
with longer strings.

Thanks,

	Ingo

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] x86/reboot: Add Dell Optiplex 7450 AIO reboot quirk
  2016-07-14 12:58 ` [PATCH] x86/reboot: Add Dell Optiplex 7450 AIO reboot quirk Ingo Molnar
@ 2016-07-14 13:16   ` Alex Hung
  2016-07-14 18:49     ` Ingo Molnar
  0 siblings, 1 reply; 3+ messages in thread
From: Alex Hung @ 2016-07-14 13:16 UTC (permalink / raw)
  To: Ingo Molnar; +Cc: tglx, mingo, hpa, x86, linux-kernel

Hi Ingo,

I agree with you but it can affect a lot of systems according to
163ea310b68bdde89b1ac633fbf8c0db290d3f86.

Do you think we should invert 163ea310 instead?

On Thu, Jul 14, 2016 at 8:58 PM, Ingo Molnar <mingo@kernel.org> wrote:
>
> * Alex Hung <alex.hung@canonical.com> wrote:
>
>> Dell Optiplex 7450 AIO works with BOOT_ACPI; however, the quirk for
>> "OptiPlex 745" changes its boot method to BOOT_BIOS and causes 7450 AIO
>> hangs when rebooting; as a result, 7450 AIO is appended to overwrite
>> BOOT_BIOS by BOOT_ACPI in order not to break the original 745 series
>>
>> Signed-off-by: Alex Hung <alex.hung@canonical.com>
>> ---
>>  arch/x86/kernel/reboot.c | 21 +++++++++++++++++++++
>>  1 file changed, 21 insertions(+)
>>
>> diff --git a/arch/x86/kernel/reboot.c b/arch/x86/kernel/reboot.c
>> index b7e1d5f..b404d05 100644
>> --- a/arch/x86/kernel/reboot.c
>> +++ b/arch/x86/kernel/reboot.c
>> @@ -55,6 +55,19 @@ bool port_cf9_safe = false;
>>   */
>>
>>  /*
>> + * Some machines require the "reboot=a" commandline options
>> + */
>> +static int __init set_acpi_reboot(const struct dmi_system_id *d)
>> +{
>> +     if (reboot_type != BOOT_ACPI) {
>> +             reboot_type = BOOT_ACPI;
>> +             pr_info("%s series board detected. Selecting %s-method for reboots.\n",
>> +                     d->ident, "ACPI");
>> +     }
>> +     return 0;
>> +}
>> +
>> +/*
>>   * Some machines require the "reboot=b" or "reboot=k"  commandline options,
>>   * this quirk makes that automatic.
>>   */
>> @@ -395,6 +408,14 @@ static struct dmi_system_id __initdata reboot_dmi_table[] = {
>>                       DMI_MATCH(DMI_PRODUCT_NAME, "Dell XPS710"),
>>               },
>>       },
>> +     {       /* Handle problems with rebooting on Dell Optiplex 7450 AIO */
>> +             .callback = set_acpi_reboot,
>> +             .ident = "Dell OptiPlex 7450 AIO",
>> +             .matches = {
>> +                     DMI_MATCH(DMI_SYS_VENDOR, "Dell Inc."),
>> +                     DMI_MATCH(DMI_PRODUCT_NAME, "OptiPlex 7450 AIO"),
>> +             },
>> +     },
>
> I think it would be better to limit the original "Dell Optiplex 745" quirk to that
> machine alone instead of quirking the quirk on one of the (known) newer models
> with longer strings.
>
> Thanks,
>
>         Ingo



-- 
Cheers,
Alex Hung

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] x86/reboot: Add Dell Optiplex 7450 AIO reboot quirk
  2016-07-14 13:16   ` Alex Hung
@ 2016-07-14 18:49     ` Ingo Molnar
  0 siblings, 0 replies; 3+ messages in thread
From: Ingo Molnar @ 2016-07-14 18:49 UTC (permalink / raw)
  To: Alex Hung; +Cc: tglx, mingo, hpa, x86, linux-kernel


* Alex Hung <alex.hung@canonical.com> wrote:

> Hi Ingo,
> 
> I agree with you but it can affect a lot of systems according to
> 163ea310b68bdde89b1ac633fbf8c0db290d3f86.
> 
> Do you think we should invert 163ea310 instead?

Reverting 163ea310 sounds like a bad idea, considering how old the commit is.

Ok, I guess we should do your patch after all. What a mess DMI based quirk gating 
is!

Thanks,

	Ingo

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-07-14 18:49 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <1468490756-28834-1-git-send-email-alex.hung@canonical.com>
2016-07-14 12:58 ` [PATCH] x86/reboot: Add Dell Optiplex 7450 AIO reboot quirk Ingo Molnar
2016-07-14 13:16   ` Alex Hung
2016-07-14 18:49     ` Ingo Molnar

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.