From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933152AbbGJPRP (ORCPT ); Fri, 10 Jul 2015 11:17:15 -0400 Received: from foss.arm.com ([217.140.101.70]:51643 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932991AbbGJPRG convert rfc822-to-8bit (ORCPT ); Fri, 10 Jul 2015 11:17:06 -0400 Date: Fri, 10 Jul 2015 16:17:40 +0100 From: Lorenzo Pieralisi To: "Moore, Robert" Cc: Ming Lei , "Zheng, Lv" , "Wysocki, Rafael J" , Linux Kernel Mailing List , linux-arm-kernel , Thomas Gleixner , Jason Cooper , "hanjun.guo@linaro.org" Subject: Re: ACPI: regression: Failed to initialize GIC IRQ controller Message-ID: <20150710151740.GB12489@red-moon> References: <94F2FBAB4432B54E8AACC7DFDE6C92E37D30B295@ORSMSX112.amr.corp.intel.com> <94F2FBAB4432B54E8AACC7DFDE6C92E37D30B2E9@ORSMSX112.amr.corp.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: 8BIT In-Reply-To: <94F2FBAB4432B54E8AACC7DFDE6C92E37D30B2E9@ORSMSX112.amr.corp.intel.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jul 10, 2015 at 03:45:32PM +0100, Moore, Robert wrote: > It's nice that someone took a sizeof() on the struct -- so, one would hope that no code actually depended on a particular value, no? Unfortunately that sizeof has been there forever (x86/ia64), ia64 code ran into a similar issue, so the check was removed to cope with lsapic MADT updates, see: arch/ia64/kernel/acpi.c line 204 /*Skip BAD_MADT_ENTRY check, as lsapic size could vary */ Is checking the subtable length field against a static value really worthwhile/suitable ? Thanks, Lorenzo > > -----Original Message----- > > From: Ming Lei [mailto:ming.lei@canonical.com] > > Sent: Friday, July 10, 2015 7:43 AM > > To: Moore, Robert > > Cc: Zheng, Lv; Wysocki, Rafael J; Linux Kernel Mailing List; linux-arm- > > kernel; Thomas Gleixner; Jason Cooper; Hanjun Guo > > Subject: Re: ACPI: regression: Failed to initialize GIC IRQ controller > > > > On Fri, Jul 10, 2015 at 10:28 PM, Moore, Robert > > wrote: > > > > > > > > >> -----Original Message----- > > >> From: Ming Lei [mailto:ming.lei@canonical.com] > > >> Sent: Friday, July 10, 2015 12:46 AM > > >> To: Moore, Robert; Zheng, Lv; Wysocki, Rafael J > > >> Cc: Linux Kernel Mailing List; linux-arm-kernel; Thomas Gleixner; > > >> Jason Cooper; Hanjun Guo > > >> Subject: ACPI: regression: Failed to initialize GIC IRQ controller > > >> > > >> Hi, > > >> > > >> Commit 0cff8dc0099f6d4f(ACPICA: ACPI 6.0: Add changes for MADT > > >> table.) causes the following failure on APM mustang board(arm64) when > > >> booting via UEFI and ACPI: > > > > > > > > > I would be interested to know just what exactly about this change broke > > things. > > > > sizeof(struct acpi_madt_generic_interrupt) > N???????????????r??????y?????????b???X????????v???^???)??{.n???+????????????{????????????zX??????????????}???????????z???&j:+v?????????????????????zZ+??????+zf?????????h?????????~????????????i?????????z??????w??????????????????????&???)??f??????^j??y???m??????@A???a????????? 0??????h??????i From mboxrd@z Thu Jan 1 00:00:00 1970 From: lorenzo.pieralisi@arm.com (Lorenzo Pieralisi) Date: Fri, 10 Jul 2015 16:17:40 +0100 Subject: ACPI: regression: Failed to initialize GIC IRQ controller In-Reply-To: <94F2FBAB4432B54E8AACC7DFDE6C92E37D30B2E9@ORSMSX112.amr.corp.intel.com> References: <94F2FBAB4432B54E8AACC7DFDE6C92E37D30B295@ORSMSX112.amr.corp.intel.com> <94F2FBAB4432B54E8AACC7DFDE6C92E37D30B2E9@ORSMSX112.amr.corp.intel.com> Message-ID: <20150710151740.GB12489@red-moon> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On Fri, Jul 10, 2015 at 03:45:32PM +0100, Moore, Robert wrote: > It's nice that someone took a sizeof() on the struct -- so, one would hope that no code actually depended on a particular value, no? Unfortunately that sizeof has been there forever (x86/ia64), ia64 code ran into a similar issue, so the check was removed to cope with lsapic MADT updates, see: arch/ia64/kernel/acpi.c line 204 /*Skip BAD_MADT_ENTRY check, as lsapic size could vary */ Is checking the subtable length field against a static value really worthwhile/suitable ? Thanks, Lorenzo > > -----Original Message----- > > From: Ming Lei [mailto:ming.lei at canonical.com] > > Sent: Friday, July 10, 2015 7:43 AM > > To: Moore, Robert > > Cc: Zheng, Lv; Wysocki, Rafael J; Linux Kernel Mailing List; linux-arm- > > kernel; Thomas Gleixner; Jason Cooper; Hanjun Guo > > Subject: Re: ACPI: regression: Failed to initialize GIC IRQ controller > > > > On Fri, Jul 10, 2015 at 10:28 PM, Moore, Robert > > wrote: > > > > > > > > >> -----Original Message----- > > >> From: Ming Lei [mailto:ming.lei at canonical.com] > > >> Sent: Friday, July 10, 2015 12:46 AM > > >> To: Moore, Robert; Zheng, Lv; Wysocki, Rafael J > > >> Cc: Linux Kernel Mailing List; linux-arm-kernel; Thomas Gleixner; > > >> Jason Cooper; Hanjun Guo > > >> Subject: ACPI: regression: Failed to initialize GIC IRQ controller > > >> > > >> Hi, > > >> > > >> Commit 0cff8dc0099f6d4f(ACPICA: ACPI 6.0: Add changes for MADT > > >> table.) causes the following failure on APM mustang board(arm64) when > > >> booting via UEFI and ACPI: > > > > > > > > > I would be interested to know just what exactly about this change broke > > things. > > > > sizeof(struct acpi_madt_generic_interrupt) > N???????????????r??????y?????????b???X????????v???^???)??{.n???+????????????{????????????zX??????????????}???????????z???&j:+v?????????????????????zZ+??????+zf?????????h?????????~????????????i?????????z??? ???w??????????????????????&???)??f??????^j??y???m??????@A???a????????? 0??????h??????i