From patchwork Tue Sep 16 00:47:23 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Suthikulpanit, Suravee" X-Patchwork-Id: 37437 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wg0-f71.google.com (mail-wg0-f71.google.com [74.125.82.71]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 853A4203E6 for ; Tue, 16 Sep 2014 02:34:02 +0000 (UTC) Received: by mail-wg0-f71.google.com with SMTP id x12sf2666572wgg.6 for ; Mon, 15 Sep 2014 19:34:01 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe:content-type; bh=bUSqblbyKBC4XzXn128zVHF4ZPGXexSaD2Z479HPi8A=; b=Mol/9ZjtCVaRyCyuzYw3wY2xgSU+FYOyIGTrLcaw0o48XPYt66wVSr0RWOIQIStzY/ vHvI2hyVYBtcgmTd05zUzlHk1elY7HstG7LrsaDQPSz5SbO0ikl/U2WeuL8cn+9XDS3O 20YVL/fq9rVL0l/O5SChNBEg8zSv+05hV0MjZcpX8iHvyB+j9feDyzNTYmlXinstR3CJ oXLHiV9Du0hQJtQpPNxdnjGzz3WmdZOUxYupBbqlgncfRC45wHrb0xyz10gWKZwMiiqU zyIgO70MUW/W/ALpPNjoIPLa/3wvDlRXejIBzjykNLqK0RcbGoyZRkX+ZAdOxP6VoRge 9+Vw== X-Gm-Message-State: ALoCoQnXmggusvrea73jKAKRHmhUMj/lEhWhnbe8/VjMiarckatVmNpwLEWiW0GhSVSblR+E+Iqb X-Received: by 10.112.137.230 with SMTP id ql6mr2220lbb.13.1410834841669; Mon, 15 Sep 2014 19:34:01 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.205.76 with SMTP id le12ls313302lac.34.gmail; Mon, 15 Sep 2014 19:34:01 -0700 (PDT) X-Received: by 10.152.28.230 with SMTP id e6mr33174646lah.62.1410834841490; Mon, 15 Sep 2014 19:34:01 -0700 (PDT) Received: from mail-la0-f41.google.com (mail-la0-f41.google.com [209.85.215.41]) by mx.google.com with ESMTPS id t1si21783174lbv.79.2014.09.15.19.34.01 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 15 Sep 2014 19:34:01 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.41 as permitted sender) client-ip=209.85.215.41; Received: by mail-la0-f41.google.com with SMTP id s18so5946594lam.28 for ; Mon, 15 Sep 2014 19:34:01 -0700 (PDT) X-Received: by 10.112.62.200 with SMTP id a8mr30615864lbs.34.1410834841215; Mon, 15 Sep 2014 19:34:01 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.130.169 with SMTP id of9csp318848lbb; Mon, 15 Sep 2014 19:34:00 -0700 (PDT) X-Received: by 10.67.23.136 with SMTP id ia8mr11521692pad.125.1410834838857; Mon, 15 Sep 2014 19:33:58 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id fr3si26613080pbd.34.2014.09.15.19.33.58 for ; Mon, 15 Sep 2014 19:33:58 -0700 (PDT) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754179AbaIPCdp (ORCPT + 27 others); Mon, 15 Sep 2014 22:33:45 -0400 Received: from mail-bn1on0132.outbound.protection.outlook.com ([157.56.110.132]:11728 "EHLO na01-bn1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752716AbaIPCdi (ORCPT ); Mon, 15 Sep 2014 22:33:38 -0400 Received: from BLUPR02MB018.namprd02.prod.outlook.com (10.242.191.25) by BLUPR02MB501.namprd02.prod.outlook.com (10.141.82.13) with Microsoft SMTP Server (TLS) id 15.0.1029.13; Tue, 16 Sep 2014 02:33:31 +0000 Received: from BY1PR0201CA0008.namprd02.prod.outlook.com (25.160.191.146) by BLUPR02MB018.namprd02.prod.outlook.com (10.242.191.25) with Microsoft SMTP Server (TLS) id 15.0.1029.13; Tue, 16 Sep 2014 02:33:30 +0000 Received: from BN1BFFO11FD025.protection.gbl (2a01:111:f400:7c10::1:124) by BY1PR0201CA0008.outlook.office365.com (2a01:111:e400:4814::18) with Microsoft SMTP Server (TLS) id 15.0.1029.13 via Frontend Transport; Tue, 16 Sep 2014 02:33:29 +0000 Received: from atltwp02.amd.com (165.204.84.222) by BN1BFFO11FD025.mail.protection.outlook.com (10.58.144.88) with Microsoft SMTP Server id 15.0.1019.14 via Frontend Transport; Tue, 16 Sep 2014 02:33:28 +0000 X-WSS-ID: 0NBZ33N-08-TSU-02 X-M-MSG: Received: from satlvexedge02.amd.com (satlvexedge02.amd.com [10.177.96.29]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by atltwp02.amd.com (Axway MailGate 5.3.1) with ESMTPS id 26375BD88E4; Mon, 15 Sep 2014 21:33:22 -0500 (CDT) Received: from SATLEXDAG01.amd.com (10.181.40.3) by SATLVEXEDGE02.amd.com (10.177.96.29) with Microsoft SMTP Server (TLS) id 14.3.195.1; Mon, 15 Sep 2014 21:33:34 -0500 Received: from ssuthiku-fedora-lt.amd.com (10.180.168.240) by SATLEXDAG01.amd.com (10.181.40.3) with Microsoft SMTP Server id 14.3.195.1; Mon, 15 Sep 2014 22:33:25 -0400 From: To: , , , CC: , , , , , , , , , , , , Suravee Suthikulpanit Subject: [PATCH 1/4] ata: ahci_platform: Add ACPI support for AMD Seattle SATA controller Date: Mon, 15 Sep 2014 19:47:23 -0500 Message-ID: <1410828446-28502-2-git-send-email-suravee.suthikulpanit@amd.com> X-Mailer: git-send-email 1.9.3 In-Reply-To: <1410828446-28502-1-git-send-email-suravee.suthikulpanit@amd.com> References: <1410828446-28502-1-git-send-email-suravee.suthikulpanit@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-Forefront-Antispam-Report: CIP:165.204.84.222; CTRY:US; IPV:NLI; EFV:NLI; SFV:NSPM; SFS:(10019020)(6009001)(428002)(189002)(199003)(85852003)(62966002)(20776003)(77096002)(106466001)(87286001)(87936001)(86152002)(89996001)(31966008)(83322001)(229853001)(53416004)(76176999)(85306004)(105586002)(2201001)(33646002)(101416001)(86362001)(97736003)(44976005)(48376002)(68736004)(93916002)(99396002)(90102001)(50226001)(50986999)(102836001)(92566001)(36756003)(92726001)(47776003)(104166001)(21056001)(88136002)(83072002)(77156001)(107046002)(84676001)(4396001)(76482001)(19580405001)(19580395003)(74662003)(74502003)(81342003)(81542003)(80022003)(79102003)(95666004)(77982003)(46102003)(2101003); DIR:OUT; SFP:1102; SCL:1; SRVR:BLUPR02MB018; H:atltwp02.amd.com; FPR:; MLV:sfv; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:;UriScan:;UriScan:; X-Forefront-PRVS: 03361FCC43 Received-SPF: None (protection.outlook.com: amd.com does not designate permitted sender hosts) X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:; X-OriginatorOrg: amd4.onmicrosoft.com Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: suravee.suthikulpanit@amd.com 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.41 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , From: Suravee Suthikulpanit This patch adds ACPI match table in ahci_platform. The table includes the acpi_device_id to match AMD Seattle SATA controller with following asl structure in DSDT: Device (SATA0) { Name(_HID, "AMDI0600") // Seattle AHSATA Name (_CCA, 1) // Cache-coherent controller Name (_CRS, ResourceTemplate () { Memory32Fixed (ReadWrite, 0xE0300000, 0x00010000) Interrupt (ResourceConsumer, Level, ActiveHigh, Exclusive,,,) { 387 } }) } Also, since ATA driver should not require PCI support for ATA_ACPI, this patch removes dependency in the driver/ata/Kconfig. --- drivers/ata/Kconfig | 2 +- drivers/ata/ahci_platform.c | 13 +++++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/drivers/ata/Kconfig b/drivers/ata/Kconfig index e1b9278..f2e6c9e 100644 --- a/drivers/ata/Kconfig +++ b/drivers/ata/Kconfig @@ -48,7 +48,7 @@ config ATA_VERBOSE_ERROR config ATA_ACPI bool "ATA ACPI Support" - depends on ACPI && PCI + depends on ACPI default y help This option adds support for ATA-related ACPI objects. diff --git a/drivers/ata/ahci_platform.c b/drivers/ata/ahci_platform.c index f61ddb9..3499bab 100644 --- a/drivers/ata/ahci_platform.c +++ b/drivers/ata/ahci_platform.c @@ -20,6 +20,9 @@ #include #include #include +#ifdef CONFIG_ATA_ACPI +#include +#endif #include "ahci.h" static const struct ata_port_info ahci_port_info = { @@ -87,6 +90,13 @@ static const struct of_device_id ahci_of_match[] = { }; MODULE_DEVICE_TABLE(of, ahci_of_match); +#ifdef CONFIG_ATA_ACPI +static const struct acpi_device_id ahci_acpi_match[] = { + { "AMDI0600", 0 }, /* AMD Seattle AHCI */ + { }, +}; +#endif + static struct platform_driver ahci_driver = { .probe = ahci_probe, .remove = ata_platform_remove_one, @@ -94,6 +104,9 @@ static struct platform_driver ahci_driver = { .name = "ahci", .owner = THIS_MODULE, .of_match_table = ahci_of_match, +#ifdef CONFIG_ATA_ACPI + .acpi_match_table = ACPI_PTR(ahci_acpi_match), +#endif .pm = &ahci_pm_ops, }, };