From patchwork Tue Sep 29 23:45:45 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Al Stone X-Patchwork-Id: 54282 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wi0-f198.google.com (mail-wi0-f198.google.com [209.85.212.198]) by patches.linaro.org (Postfix) with ESMTPS id BAE6E23009 for ; Tue, 29 Sep 2015 23:46:14 +0000 (UTC) Received: by wicuu12 with SMTP id uu12sf13601339wic.2 for ; Tue, 29 Sep 2015 16:46:14 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=7tAEO7SA95PNumPPDL9QjV2LVWFqdPQPKpitmD73AHw=; b=Xt+Q65C9tBi3sEqxUL+zh1KtovY5OLJoq75iyXhw+xMgHZM/a2r322zDsgRdUruUFV QP64a8XtD+TJ3W1LpIAwdt3WSkaEyy+0e7KnivJubKv2drJiqVbeCD2+b5EbOVb1vXUc WtWlS404JZVg6WVrjq6ZUeedNWxB85roN10ELVHe4OB7mmj7q8Cn6B3Ub8k8DIWHl5A5 s9o/dYca87fmrRw+FUpZocpagh80LTA8QoK04rsacorL8R57UhDoc/AW2WksHu6KFxpa zptxHFxZm2IS1LBqSdW9JG6W5Y+bRAmebO7qt0O5GUOUu3DJrDgWugRZ+MjkO1LhFmyu wxyg== X-Gm-Message-State: ALoCoQmRaKgpQZaqONZNj6J2AeL2UKgkqMjh2TohCKb3kRSJ1auLcJkkNzwcnDMgfhD4fNF2OTUX X-Received: by 10.112.145.3 with SMTP id sq3mr76367lbb.7.1443570374035; Tue, 29 Sep 2015 16:46:14 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.19.233 with SMTP id i9ls11742lae.4.gmail; Tue, 29 Sep 2015 16:46:13 -0700 (PDT) X-Received: by 10.25.25.83 with SMTP id 80mr98155lfz.30.1443570373736; Tue, 29 Sep 2015 16:46:13 -0700 (PDT) Received: from mail-la0-f53.google.com (mail-la0-f53.google.com. [209.85.215.53]) by mx.google.com with ESMTPS id sr10si12085209lbb.118.2015.09.29.16.46.13 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 29 Sep 2015 16:46:13 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.53 as permitted sender) client-ip=209.85.215.53; Received: by laclj5 with SMTP id lj5so26994686lac.3 for ; Tue, 29 Sep 2015 16:46:13 -0700 (PDT) X-Received: by 10.112.156.167 with SMTP id wf7mr177939lbb.88.1443570373617; Tue, 29 Sep 2015 16:46:13 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.112.59.35 with SMTP id w3csp2426896lbq; Tue, 29 Sep 2015 16:46:12 -0700 (PDT) X-Received: by 10.50.164.135 with SMTP id yq7mr1655011igb.28.1443570365945; Tue, 29 Sep 2015 16:46:05 -0700 (PDT) Received: from mail-io0-f171.google.com (mail-io0-f171.google.com. [209.85.223.171]) by mx.google.com with ESMTPS id q6si18746926igr.43.2015.09.29.16.46.05 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 29 Sep 2015 16:46:05 -0700 (PDT) Received-SPF: pass (google.com: domain of al.stone@linaro.org designates 209.85.223.171 as permitted sender) client-ip=209.85.223.171; Received: by iofb144 with SMTP id b144so29468827iof.1 for ; Tue, 29 Sep 2015 16:46:05 -0700 (PDT) X-Received: by 10.107.9.151 with SMTP id 23mr1790538ioj.170.1443570365551; Tue, 29 Sep 2015 16:46:05 -0700 (PDT) Received: from fidelio.ahs3.com (c-50-134-239-249.hsd1.co.comcast.net. [50.134.239.249]) by smtp.googlemail.com with ESMTPSA id r40sm12256182ioe.20.2015.09.29.16.46.03 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 29 Sep 2015 16:46:04 -0700 (PDT) From: Al Stone To: linux-acpi@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org, linux-ia64@vger.kernel.org, linux-pm@vger.kernel.org, linaro-acpi@lists.linaro.org, linaro-kernel@lists.linaro.org, patches@linaro.org, Al Stone , "Rafael J. Wysocki" , Len Brown , Pavel Machek , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , x86@kernel.org Subject: [PATCH v5 4/5] ACPI / X86: remove usage of BAD_MADT_ENTRY Date: Tue, 29 Sep 2015 17:45:45 -0600 Message-Id: <1443570346-15378-5-git-send-email-al.stone@linaro.org> X-Mailer: git-send-email 2.4.3 In-Reply-To: <1443570346-15378-1-git-send-email-al.stone@linaro.org> References: <1443570346-15378-1-git-send-email-al.stone@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: al.stone@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.53 as permitted sender) smtp.mailfrom=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Now that we have introduced the bad_madt_entry() function, and that function is being invoked in acpi_table_parse_madt() for us, there is no longer any need to use the BAD_MADT_ENTRY macro. Signed-off-by: Al Stone Cc: Rafael J. Wysocki Cc: Len Brown Cc: Pavel Machek Cc: Thomas Gleixner Cc: Ingo Molnar Cc: H. Peter Anvin Cc: x86@kernel.org --- arch/x86/kernel/acpi/boot.c | 27 --------------------------- 1 file changed, 27 deletions(-) diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c index e759076..e65bcea 100644 --- a/arch/x86/kernel/acpi/boot.c +++ b/arch/x86/kernel/acpi/boot.c @@ -194,9 +194,6 @@ acpi_parse_x2apic(struct acpi_subtable_header *header, const unsigned long end) processor = (struct acpi_madt_local_x2apic *)header; - if (BAD_MADT_ENTRY(processor, end)) - return -EINVAL; - acpi_table_print_madt_entry(header); apic_id = processor->local_apic_id; @@ -227,9 +224,6 @@ acpi_parse_lapic(struct acpi_subtable_header * header, const unsigned long end) processor = (struct acpi_madt_local_apic *)header; - if (BAD_MADT_ENTRY(processor, end)) - return -EINVAL; - acpi_table_print_madt_entry(header); /* @@ -252,9 +246,6 @@ acpi_parse_sapic(struct acpi_subtable_header *header, const unsigned long end) processor = (struct acpi_madt_local_sapic *)header; - if (BAD_MADT_ENTRY(processor, end)) - return -EINVAL; - acpi_table_print_madt_entry(header); acpi_register_lapic((processor->id << 8) | processor->eid,/* APIC ID */ @@ -271,9 +262,6 @@ acpi_parse_lapic_addr_ovr(struct acpi_subtable_header * header, lapic_addr_ovr = (struct acpi_madt_local_apic_override *)header; - if (BAD_MADT_ENTRY(lapic_addr_ovr, end)) - return -EINVAL; - acpi_lapic_addr = lapic_addr_ovr->address; return 0; @@ -287,9 +275,6 @@ acpi_parse_x2apic_nmi(struct acpi_subtable_header *header, x2apic_nmi = (struct acpi_madt_local_x2apic_nmi *)header; - if (BAD_MADT_ENTRY(x2apic_nmi, end)) - return -EINVAL; - acpi_table_print_madt_entry(header); if (x2apic_nmi->lint != 1) @@ -305,9 +290,6 @@ acpi_parse_lapic_nmi(struct acpi_subtable_header * header, const unsigned long e lapic_nmi = (struct acpi_madt_local_apic_nmi *)header; - if (BAD_MADT_ENTRY(lapic_nmi, end)) - return -EINVAL; - acpi_table_print_madt_entry(header); if (lapic_nmi->lint != 1) @@ -411,9 +393,6 @@ acpi_parse_ioapic(struct acpi_subtable_header * header, const unsigned long end) ioapic = (struct acpi_madt_io_apic *)header; - if (BAD_MADT_ENTRY(ioapic, end)) - return -EINVAL; - acpi_table_print_madt_entry(header); /* Statically assign IRQ numbers for IOAPICs hosting legacy IRQs */ @@ -463,9 +442,6 @@ acpi_parse_int_src_ovr(struct acpi_subtable_header * header, intsrc = (struct acpi_madt_interrupt_override *)header; - if (BAD_MADT_ENTRY(intsrc, end)) - return -EINVAL; - acpi_table_print_madt_entry(header); if (intsrc->source_irq == acpi_gbl_FADT.sci_interrupt) { @@ -504,9 +480,6 @@ acpi_parse_nmi_src(struct acpi_subtable_header * header, const unsigned long end nmi_src = (struct acpi_madt_nmi_source *)header; - if (BAD_MADT_ENTRY(nmi_src, end)) - return -EINVAL; - acpi_table_print_madt_entry(header); /* TBD: Support nimsrc entries? */