Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp49395pxk; Tue, 15 Sep 2020 17:26:55 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzl3Jv/y9sISU6AMteLLkZGLkCtfI62SJa8PJQcuRKkfeTTTDr5Siwn/YNbvTrf5Q1oBYWA X-Received: by 2002:aa7:c155:: with SMTP id r21mr25662134edp.140.1600216015459; Tue, 15 Sep 2020 17:26:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600216015; cv=none; d=google.com; s=arc-20160816; b=LPPR3T/usQiMWvF8ejaVFsZFo0pT0G8//zNbNsGpkdOyEqcFNMGqZ4vEYJMoazlQWx CjxqQLTbJw5kUOKlyxtky7ysnDiQQ6z36jn31yUa45yww3UOXNeZygeO2Hf963Uk5hF1 XaVH/uNJyYiQeDBpoguCzCY3AMskoDOApbWsSrPPcMZVL935xcIk5vd1lytgQrmEU8tZ bR7mNvlhVZAbr5GBo2hnIdCYBB13ujXiExtqtxQhP0cifkWvYHzVxgckp+FGu9Jor7t9 08ydAtDI02ayzOs3jafMZgJHnxs83xAghPewZ1KwqjAc7ydQpciO6GVspnIyVBu0xbG8 reJg== 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=Qw8uEXL7z2mumeOL52Ar2n2KfqPlu21+9bBgY/+7vIw=; b=N+DMvCuO3hEq/eBvvUpidrlInjYFGMKYcxVM5agstI+EoTy5XQl+kLl4OIg7xQ50v2 uw7b2ftbqgogOmsMBmIuQsm45fdU4QMA3vefyiekUaZfsMxmfZ/KOgO81DWT4tx4/08i jFvOTrj77P/udGd5cYykq6dulL5gAhdNweHWOenHQ4f07ZmKRO9rpBOdNdgw1uOsuuBd e5SXznOQNoOWmeyn7kFvusfqsIWtDl8XHEsTHxMJ1ovRWr6D6ELnX1gDgpUf2ChAI1Vl lcJvptLpA9gfz6Mtakk/XEO+eiM8pahZ2YC/VLsh9JovZAgijJv8A4eigJlRz5wM4ETl qkRw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="UjQF7VB/"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id r10si10786717ejr.168.2020.09.15.17.26.32; Tue, 15 Sep 2020 17:26:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="UjQF7VB/"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727485AbgIPAXh (ORCPT + 99 others); Tue, 15 Sep 2020 20:23:37 -0400 Received: from mail.kernel.org ([198.145.29.99]:60722 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726691AbgIOOU6 (ORCPT ); Tue, 15 Sep 2020 10:20:58 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (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 B2F8B22245; Tue, 15 Sep 2020 14:16:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1600179410; bh=wuwVLdXX2n13+HfWQm1zOODVzzKlPBYPTWU70RzIDXA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=UjQF7VB/bOI5Se8ZgPsG4pRLXk+y+7UWyG7kU9ND19jEb+o5HcnOaiWv2Sgaz3V/F dSFkiRYB3hyYhT1mjARspvCH1X241gpvFbJajutHZXaJI15R+kxnmZBWaWw/xFXXwl gydgHVFLQ9poXHNELr7NZjwQrTemN+AmLZ8dWrAg= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Martin Schiller , Xie He , Krzysztof Halasa , "David S. Miller" , Sasha Levin Subject: [PATCH 4.19 31/78] drivers/net/wan/hdlc_cisco: Add hard_header_len Date: Tue, 15 Sep 2020 16:12:56 +0200 Message-Id: <20200915140635.142645939@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200915140633.552502750@linuxfoundation.org> References: <20200915140633.552502750@linuxfoundation.org> User-Agent: quilt/0.66 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 From: Xie He [ Upstream commit 1a545ebe380bf4c1433e3c136e35a77764fda5ad ] This driver didn't set hard_header_len. This patch sets hard_header_len for it according to its header_ops->create function. This driver's header_ops->create function (cisco_hard_header) creates a header of (struct hdlc_header), so hard_header_len should be set to sizeof(struct hdlc_header). Cc: Martin Schiller Signed-off-by: Xie He Acked-by: Krzysztof Halasa Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- drivers/net/wan/hdlc_cisco.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/wan/hdlc_cisco.c b/drivers/net/wan/hdlc_cisco.c index 320039d329c7d..c169a26e5359a 100644 --- a/drivers/net/wan/hdlc_cisco.c +++ b/drivers/net/wan/hdlc_cisco.c @@ -374,6 +374,7 @@ static int cisco_ioctl(struct net_device *dev, struct ifreq *ifr) memcpy(&state(hdlc)->settings, &new_settings, size); spin_lock_init(&state(hdlc)->lock); dev->header_ops = &cisco_header_ops; + dev->hard_header_len = sizeof(struct hdlc_header); dev->type = ARPHRD_CISCO; call_netdevice_notifiers(NETDEV_POST_TYPE_CHANGE, dev); netif_dormant_on(dev); -- 2.25.1