Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp2650587imj; Mon, 11 Feb 2019 06:28:53 -0800 (PST) X-Google-Smtp-Source: AHgI3IYihPuCt/Kekopfly6DqXlYQc3UW3z++D6V9fYoG9JEmRVSr5PCMY1Dn28wp2vlzgJX4Kvt X-Received: by 2002:a17:902:e087:: with SMTP id cb7mr32782501plb.313.1549895333873; Mon, 11 Feb 2019 06:28:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549895333; cv=none; d=google.com; s=arc-20160816; b=r1A6tagTSl0WgAscE/WFFsP8Bia4O8ldLy7zH8RRAtts7zXs5M7eo8YMbmXs9Ho+2a uMWQXd43whQuRq3O8o09ZIEZLSs6rxVByve4T0qEMMO3kLwW7f5P28RrW38nJsasahBX wIjYNvuzqHgzYC4l8cXMwZYjVwDG+NRV55WXFMrkcPzaP/mEAr3wMoFVNvp8LsKUPLXX qAzLeZxd+lBstY/UfiJqQcJxhRd6kFDkWd7uhgZ6WfpBMjf+3vx07WgiWpaj7YChzddM 8aNf25NC5hmPXqiYJ5FfvJixjcINSp4JNyLc57jamS+I1wfd/0okEkG+CSesV2SSNhiQ t/iw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=AtnZ718KtmZf84tM6WrFu+ueB0qT0U2od6hkWpWTvZc=; b=huLbwvAj3QSeCU8LMlOtrlpkQ9HMMBqlKcCg1IDzpKdCWPUGB7vv62sfNXok1AZUjO XC+ADyblpjeAferNw8IArqg2EajXGH+BQoNiBjTXti4VHUQYQMzit5dt0DZQ1/cvsGMs mVJDE0w/0SJkT0A4vJf/Rsa2QxAlLiFiN3PM7MwKc8d6QNiNAT7Te07P+YDvQ7OlgQCK 9yC+OdMYdRHC57H/dyf2If4LEBfggg3kagXRtGg3xBdX13Kr8REEb4zmlz625IdhwkKZ 44xne8FZhrFbLa3yx+RmHNW+UKXs195gv7HdjZO8ubYVV9BB11oVzp0+ylCuZZRSX5DC qg4g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=FCeqNJF3; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n23si2138907pff.10.2019.02.11.06.28.37; Mon, 11 Feb 2019 06:28:53 -0800 (PST) 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=@kernel.org header.s=default header.b=FCeqNJF3; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729126AbfBKOYM (ORCPT + 99 others); Mon, 11 Feb 2019 09:24:12 -0500 Received: from mail.kernel.org ([198.145.29.99]:57270 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727835AbfBKOYI (ORCPT ); Mon, 11 Feb 2019 09:24:08 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 57B8120821; Mon, 11 Feb 2019 14:24:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1549895047; bh=hNvfpttkZ+QDnKyPstn9n0HlFOAmGKoPkYpAnRkNq58=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=FCeqNJF3B4td9vPSudjLa1Omw53HanHpiIIvMpZq5QnPmUkz6MuO/IPCpSTlrMStj OCeU4NcvgFe+xrpv5F54ualxHKJArjjZAzwFT59lfBcpi/8otcPSTOm0u+n0SceADO /qjI7XGw2wEKMpV4gL+VHeuEyKaBNpWcd+EzrR1E= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Ben Dooks , "David S. Miller" , Sasha Levin Subject: [PATCH 4.20 046/352] usbnet: smsc95xx: fix rx packet alignment Date: Mon, 11 Feb 2019 15:14:33 +0100 Message-Id: <20190211141849.224223353@linuxfoundation.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190211141846.543045703@linuxfoundation.org> References: <20190211141846.543045703@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review X-Patchwork-Hint: ignore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.20-stable review patch. If anyone has any objections, please let me know. ------------------ [ Upstream commit 810eeb1f41a9a272eedc94ca18c072e75678ede4 ] The smsc95xx driver already takes into account the NET_IP_ALIGN parameter when setting up the receive packet data, which means we do not need to worry about aligning the packets in the usbnet driver. Adding the EVENT_NO_IP_ALIGN means that the IPv4 header is now passed to the ip_rcv() routine with the start on an aligned address. Tested on Raspberry Pi B3. Signed-off-by: Ben Dooks Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- drivers/net/usb/smsc95xx.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/usb/smsc95xx.c b/drivers/net/usb/smsc95xx.c index f2d01cb6f958..6e971628bb50 100644 --- a/drivers/net/usb/smsc95xx.c +++ b/drivers/net/usb/smsc95xx.c @@ -1295,6 +1295,7 @@ static int smsc95xx_bind(struct usbnet *dev, struct usb_interface *intf) dev->net->features |= NETIF_F_RXCSUM; dev->net->hw_features = NETIF_F_IP_CSUM | NETIF_F_RXCSUM; + set_bit(EVENT_NO_IP_ALIGN, &dev->flags); smsc95xx_init_mac_address(dev); -- 2.19.1