From patchwork Fri Oct 10 15:15:37 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Murali Karicheri X-Patchwork-Id: 38591 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ee0-f71.google.com (mail-ee0-f71.google.com [74.125.83.71]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 2720F205D8 for ; Fri, 10 Oct 2014 15:16:23 +0000 (UTC) Received: by mail-ee0-f71.google.com with SMTP id d17sf2340481eek.10 for ; Fri, 10 Oct 2014 08:16:22 -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 :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=EGQswVlXGDwi5pkd3gY3z7WalAjdj9HJOytSe3PM1Zc=; b=QvQq0F0+A+NaEmOM8A/09T5VRSWF2D6N7pLnktXH+UYggu37d4XL7Vck+X6OLX34gX 7QiFwj+fSvR0kkdQum2P283CVzE2H/bWjornlv8jYabsYwwKRksUjCehJc5J86dMqOAO 7swQp+lPNu9RpSK6JRzeHDXCvbjZGcJRkj7u2F7MQ+4Jr4f/YvxHWRXDyByugAluNwSK f5oGcoaDJZBGzSowSZNmOVN3SxcCVsSz1Ck0m4xPZscJbE3ht+muJnEDb1NmyYl6Z66B oFHSdbLi2zIdL1MKDmPO5u+E4asRZe+FZe8PATgfq9mx7AxEYXOXux7dc+MIYayNvsUt zatw== X-Gm-Message-State: ALoCoQmrX1P4GS71i1UyjHSeqfRmyGFoFa0iVTld9cSpMr2AJOMwHTK46Jn71iKPQuIG7dZOlgW1 X-Received: by 10.180.76.230 with SMTP id n6mr1181290wiw.0.1412954182338; Fri, 10 Oct 2014 08:16:22 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.198.201 with SMTP id je9ls302614lac.92.gmail; Fri, 10 Oct 2014 08:16:22 -0700 (PDT) X-Received: by 10.112.185.68 with SMTP id fa4mr5345513lbc.77.1412954182046; Fri, 10 Oct 2014 08:16:22 -0700 (PDT) Received: from mail-lb0-f175.google.com (mail-lb0-f175.google.com [209.85.217.175]) by mx.google.com with ESMTPS id h7si6694042lae.93.2014.10.10.08.16.21 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 10 Oct 2014 08:16:21 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.175 as permitted sender) client-ip=209.85.217.175; Received: by mail-lb0-f175.google.com with SMTP id u10so3315200lbd.34 for ; Fri, 10 Oct 2014 08:16:21 -0700 (PDT) X-Received: by 10.152.23.170 with SMTP id n10mr5592503laf.29.1412954181883; Fri, 10 Oct 2014 08:16:21 -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.84.229 with SMTP id c5csp447074lbz; Fri, 10 Oct 2014 08:16:21 -0700 (PDT) X-Received: by 10.66.65.130 with SMTP id x2mr5810454pas.79.1412954180367; Fri, 10 Oct 2014 08:16:20 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id gl5si3844604pbc.229.2014.10.10.08.16.19 for ; Fri, 10 Oct 2014 08:16:20 -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 S1754380AbaJJPQQ (ORCPT + 27 others); Fri, 10 Oct 2014 11:16:16 -0400 Received: from arroyo.ext.ti.com ([192.94.94.40]:49939 "EHLO arroyo.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751837AbaJJPQM (ORCPT ); Fri, 10 Oct 2014 11:16:12 -0400 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by arroyo.ext.ti.com (8.13.7/8.13.7) with ESMTP id s9AFFcM0015568; Fri, 10 Oct 2014 10:15:38 -0500 Received: from DLEE70.ent.ti.com (dlee70.ent.ti.com [157.170.170.113]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id s9AFFcJr027665; Fri, 10 Oct 2014 10:15:38 -0500 Received: from dflp33.itg.ti.com (10.64.6.16) by DLEE70.ent.ti.com (157.170.170.113) with Microsoft SMTP Server id 14.3.174.1; Fri, 10 Oct 2014 10:15:37 -0500 Received: from localhost.localdomain (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp33.itg.ti.com (8.14.3/8.13.8) with ESMTP id s9AFFb3N026015; Fri, 10 Oct 2014 10:15:37 -0500 From: Murali Karicheri To: , , , CC: Murali Karicheri Subject: [PATCH] ARM: keystone: add bus notifier to set dma_pfn_offset for pci devices Date: Fri, 10 Oct 2014 11:15:37 -0400 Message-ID: <1412954137-4567-1-git-send-email-m-karicheri2@ti.com> X-Mailer: git-send-email 1.7.9.5 MIME-Version: 1.0 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: m-karicheri2@ti.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.217.175 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: , When PCI device driver such as that for e1000e tries to set dma mask using dma_set_mask_and_coherent(), it fails because the dma_pfn_offset is incorrect on a Keystone SoC. This patch fix this by adding a bus notifier to set this correctly for PCI devices. Signed-off-by: Murali Karicheri --- arch/arm/mach-keystone/keystone.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/mach-keystone/keystone.c b/arch/arm/mach-keystone/keystone.c index 7f352de..13afe95 100644 --- a/arch/arm/mach-keystone/keystone.c +++ b/arch/arm/mach-keystone/keystone.c @@ -15,6 +15,7 @@ #include #include #include +#include #include #include @@ -54,6 +55,8 @@ static void __init keystone_init(void) keystone_pm_runtime_init(); if (platform_nb.notifier_call) bus_register_notifier(&platform_bus_type, &platform_nb); + if (platform_nb.notifier_call) + bus_register_notifier(&pci_bus_type, &platform_nb); of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL); }