Received: by 10.213.65.68 with SMTP id h4csp1687979imn; Mon, 19 Mar 2018 10:35:04 -0700 (PDT) X-Google-Smtp-Source: AG47ELvIuT6ealI1Ycj7exnqpO7Cv2Nh2j52PoTIjX0kzDAh2rYnX4NvHZZjyzY+cYj7GdB1owNw X-Received: by 10.98.71.3 with SMTP id u3mr10918957pfa.219.1521480904318; Mon, 19 Mar 2018 10:35:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521480904; cv=none; d=google.com; s=arc-20160816; b=t0EVVHQGaV2GHmOcH+mrggZpHZeYW+Fd0fDR4FrwmKiLYA3nZYnvilZ9Xa0EnqLqlA g9vpDKRmXM2NsJhZb44WUZyw2RRfuW71DgRJ2kViZSJXwRMTn73TFt+Gd5EdKSUtHoer qwrPyak83T2DPoTs73SDSKrJvFZ76kpDcG0PQDpSXZv4w1+AZGhKPsEAA1Rs0UOUOXxw nmi507OVI1ij61bAJRK8rDdghISlU4ZuKtJCUc4Low6dho3q8etlhj2F1C4JrygCP8NY HjhcDCi+KsYjrsEN6hSYmUvycqsIlzGiwwR4yaekiyp0vtw7K+/zwR4MmBpwr+DOG19v 28TA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :spamdiagnosticmetadata:spamdiagnosticoutput:content-language :accept-language:in-reply-to:references:message-id:date:thread-index :thread-topic:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=rjNK28W3i2hLenFKkoIkdqK3mnMP6TYIA1nDDGHBt9I=; b=zxDrhj6NM47cScveLKbQciAGosIHlYiJEp4YML9GQ9QkrfCBD1ObXsH568Yoa1zn6m iC/YGEzjn1ujovF8V0Ou9dEYdNRhFo6sQjLp5rFCqBZQkbvX3N+mqFuF3KDhJ8qcvxze fYyqHhF8fhk/xLQ92e0WfGEQXQnzlcDTmvw8ThXLbwwLLs1P6O7k03f9Qq/5gyTLK/Lb 1BP6r5gt2sxfv9KtZ/7xjStLx+Ia2++3RbY0aHkpqjL8tNB1HtOSpiw2Oczn0v8LuTNh iCiHHS5gBwPrU7H8o2v4c1q9Wn/Q9Ba970ozRDyKHZleKFvYIWIVqBJP+3qrWJ9Z03hP tzQg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@microsoft.com header.s=selector1 header.b=Mis4l9vD; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=microsoft.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s10si255124pfk.369.2018.03.19.10.34.48; Mon, 19 Mar 2018 10:35:04 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@microsoft.com header.s=selector1 header.b=Mis4l9vD; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=microsoft.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S966158AbeCSRcW (ORCPT + 99 others); Mon, 19 Mar 2018 13:32:22 -0400 Received: from mail-cys01nam02on0100.outbound.protection.outlook.com ([104.47.37.100]:20505 "EHLO NAM02-CY1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S966025AbeCSQG6 (ORCPT ); Mon, 19 Mar 2018 12:06:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=rjNK28W3i2hLenFKkoIkdqK3mnMP6TYIA1nDDGHBt9I=; b=Mis4l9vD7amGcswLro/uZL5tRUnaWG6tUZDKCqnWOJfoOZr3gTYqFo5JCXGE//Mzu0HHJiZZMvXV+/IEigoLDEMCfpOCZfbIbxw8dKu6eyebTyuRNYJpwwaP430fCt0drNk6vqZ60ZcmNEo5xu90lGvBymoT5Kh1mirxnOHpLVo= Received: from DM5PR2101MB1032.namprd21.prod.outlook.com (52.132.128.13) by DM5PR2101MB1093.namprd21.prod.outlook.com (52.132.130.15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.631.0; Mon, 19 Mar 2018 16:06:51 +0000 Received: from DM5PR2101MB1032.namprd21.prod.outlook.com ([fe80::3d9b:79e7:94eb:5d62]) by DM5PR2101MB1032.namprd21.prod.outlook.com ([fe80::3d9b:79e7:94eb:5d62%5]) with mapi id 15.20.0631.004; Mon, 19 Mar 2018 16:06:51 +0000 From: Sasha Levin To: "linux-kernel@vger.kernel.org" , "stable@vger.kernel.org" CC: Stefan Wahren , "David S . Miller" , Sasha Levin Subject: [PATCH AUTOSEL for 4.4 022/167] net: qca_spi: Fix alignment issues in rx path Thread-Topic: [PATCH AUTOSEL for 4.4 022/167] net: qca_spi: Fix alignment issues in rx path Thread-Index: AQHTv5wlx+eAelyjQESK3ud5b26isA== Date: Mon, 19 Mar 2018 16:05:48 +0000 Message-ID: <20180319160513.16384-22-alexander.levin@microsoft.com> References: <20180319160513.16384-1-alexander.levin@microsoft.com> In-Reply-To: <20180319160513.16384-1-alexander.levin@microsoft.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [52.168.54.252] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;DM5PR2101MB1093;7:hx4uaTgJgOB7VIEi/DhcuX+BPQZMrokyYJax45sjOJJw7qRxhC0zY0KPuEKtiBe/kn1UyjceHz0r1VX4yyTo4WfRXyMR2Hqbjlxo4S+Dsd5cSAdPlq43OBU8o0DZbNZsf2yHHdyyrOB9AT7y9Pa+9a6NVhhmo264h5MS7zZU82UZ1Dy7z/38ULsqewqRVaeXRp7lmOO6Yn+GFECpuae840eKvARZruVcmEyizi9aCBxE/F/tYS5diy0kCP21zxNL;20:VJw3JzlWgZmZDqiuUIleH2HCJnM7Mat7tbwPtgL2Trg1nCJEw7yCGT2dNEC5ADAM6NGqsLsRZrDOr87Cx1YkE+pAh/MHAF0ZcaRLfFYWU+KBrYRoaCBzJUHqVMgphTxkRF+R9bXIRAUnOcw56x9gdtyUgbvzTtVO8+xz6PQCyk0= x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: 10e00f81-5c5d-4c4d-33eb-08d58db36d38 x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(7020095)(4652020)(48565401081)(5600026)(4604075)(3008032)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7193020);SRVR:DM5PR2101MB1093; x-ms-traffictypediagnostic: DM5PR2101MB1093: authentication-results: spf=none (sender IP is ) smtp.mailfrom=Alexander.Levin@microsoft.com; x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(28532068793085)(89211679590171); x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(8211001083)(61425038)(6040522)(2401047)(5005006)(8121501046)(3231221)(944501300)(52105095)(3002001)(93006095)(93001095)(10201501046)(6055026)(61426038)(61427038)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123562045)(20161123564045)(20161123558120)(6072148)(201708071742011);SRVR:DM5PR2101MB1093;BCL:0;PCL:0;RULEID:;SRVR:DM5PR2101MB1093; x-forefront-prvs: 06167FAD59 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(376002)(396003)(39380400002)(366004)(39860400002)(346002)(189003)(199004)(10290500003)(68736007)(478600001)(110136005)(72206003)(36756003)(99286004)(97736004)(10090500001)(305945005)(7736002)(6666003)(76176011)(107886003)(2950100002)(6436002)(86612001)(6486002)(4326008)(54906003)(186003)(3660700001)(25786009)(26005)(2906002)(53936002)(5250100002)(2501003)(81166006)(81156014)(2900100001)(86362001)(5660300001)(8936002)(1076002)(8676002)(3846002)(3280700002)(6116002)(66066001)(316002)(6506007)(14454004)(106356001)(6512007)(22452003)(105586002)(102836004)(22906009)(217873001);DIR:OUT;SFP:1102;SCL:1;SRVR:DM5PR2101MB1093;H:DM5PR2101MB1032.namprd21.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: microsoft.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: YA4axyG0yqmfIkvP8H+OTbxEGrFTTPXxxk5FRAMFMExAdCj5IYYl/EVqQmNRsfQoInRT7kQ9qZVvQtl3adzULEyWcpYOqG4wMrhs1gu/OoLAnU8PipC1I/xo9A27w+WSMNGBJNxqIp0lxbslnB5fYXnTJJ1carDrvrX4k5/vSuJytaScy49rKFFN4RFsBe2LRfZiksdgy1Wm8ERwae8/PpBuhnHetv4qLy18PsbxSDke4xXTal9FtqRlg3nviHSvLPl0WK5GwtawehHSqc7c6Ag7KKJlCDnjP3ci2BcrsnSkXdC8BzixUtcuoPZAKteloKh2FGUzKgYHTeenJa/cXg== spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: microsoft.com X-MS-Exchange-CrossTenant-Network-Message-Id: 10e00f81-5c5d-4c4d-33eb-08d58db36d38 X-MS-Exchange-CrossTenant-originalarrivaltime: 19 Mar 2018 16:05:48.8062 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 72f988bf-86f1-41af-91ab-2d7cd011db47 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR2101MB1093 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Stefan Wahren [ Upstream commit 8d66c30b12ed3cb533696dea8b9a9eadd5da426a ] The qca_spi driver causes alignment issues on ARM devices. So fix this by using netdev_alloc_skb_ip_align(). Signed-off-by: Stefan Wahren Fixes: 291ab06ecf67 ("net: qualcomm: new Ethernet over SPI driver for QCA70= 00") Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- drivers/net/ethernet/qualcomm/qca_spi.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/drivers/net/ethernet/qualcomm/qca_spi.c b/drivers/net/ethernet= /qualcomm/qca_spi.c index 1ef03939d25f..c90ae4d4be7d 100644 --- a/drivers/net/ethernet/qualcomm/qca_spi.c +++ b/drivers/net/ethernet/qualcomm/qca_spi.c @@ -296,8 +296,9 @@ qcaspi_receive(struct qcaspi *qca) =20 /* Allocate rx SKB if we don't have one available. */ if (!qca->rx_skb) { - qca->rx_skb =3D netdev_alloc_skb(net_dev, - net_dev->mtu + VLAN_ETH_HLEN); + qca->rx_skb =3D netdev_alloc_skb_ip_align(net_dev, + net_dev->mtu + + VLAN_ETH_HLEN); if (!qca->rx_skb) { netdev_dbg(net_dev, "out of RX resources\n"); qca->stats.out_of_mem++; @@ -377,7 +378,7 @@ qcaspi_receive(struct qcaspi *qca) qca->rx_skb, qca->rx_skb->dev); qca->rx_skb->ip_summed =3D CHECKSUM_UNNECESSARY; netif_rx_ni(qca->rx_skb); - qca->rx_skb =3D netdev_alloc_skb(net_dev, + qca->rx_skb =3D netdev_alloc_skb_ip_align(net_dev, net_dev->mtu + VLAN_ETH_HLEN); if (!qca->rx_skb) { netdev_dbg(net_dev, "out of RX resources\n"); @@ -759,7 +760,8 @@ qcaspi_netdev_init(struct net_device *dev) if (!qca->rx_buffer) return -ENOBUFS; =20 - qca->rx_skb =3D netdev_alloc_skb(dev, qca->net_dev->mtu + VLAN_ETH_HLEN); + qca->rx_skb =3D netdev_alloc_skb_ip_align(dev, qca->net_dev->mtu + + VLAN_ETH_HLEN); if (!qca->rx_skb) { kfree(qca->rx_buffer); netdev_info(qca->net_dev, "Failed to allocate RX sk_buff.\n"); --=20 2.14.1