Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp1682854ybb; Sat, 11 Apr 2020 09:12:56 -0700 (PDT) X-Google-Smtp-Source: APiQypLImVB4vidnR8UWz0PtFnJdvH/kR9jc24MT5hIDQwmjOGJcmTmYOYAEgK3AArx7+F7ouFdl X-Received: by 2002:a37:418d:: with SMTP id o135mr9186364qka.349.1586621576469; Sat, 11 Apr 2020 09:12:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586621576; cv=none; d=google.com; s=arc-20160816; b=fukV2BLbG+y6jVJcnBl1llEXY86HSkLbgRHLUx3QZDcsAuq+8eCdYZBviH4VE+yxTv 51fSnmrusfkZxzYFY/3LhWlTUBEWGKkTg4u1G4Uqmt6dy7h348jgLrOmYRApA70ldyhf BrnRYab2Co01LzltKcBFR2NT+TCWw17GwP2FKHznZBMJZ62atcMCodxn975hxC46JQWo ZpNO2FeJrYaGiHbK5njRJXp0nAjPeS4r0UVI8HzUC95vs8IMFKclnaMYVZUR0zJDtqvP 1g7fylWSYgosfo5QtFbXIO0lD63+iraHTNTu8CW2RVV+R7rgJ+Af4p/P/W6O8Ov6Ab4P F8Dg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=6hoiIAnxBZeBKP57fzh8MFJBTZRZYAbl80YxSdBDylg=; b=XsROdZfI7UBK4TECf8TokBwXFLkIR239f+hHhKuXsH3eYFgx/j24JUB5qmRESrE/IG fn6E+mvX619r0gHO+gYqNCs4fODnltcL+BVwUrx2hAV2xezTrs/Nc0rNQV2Qh10u8py5 6vD40KOXOaVOB31FlbpuB7EZflKl/UvpsOCTa7NiL/A7w/QNnmxaaXJSNBTgBRmRJO9h Xj7k12TGOzqTkHzk9IgJLXcEWLrJq5QxMuS6/hO6Yja1QGs5kNtCorOVcbqSuIjMtSIC fmAnHOxRlqCUAwD1qM8Hsz6BUFG7GW2B4D4GsuzksNx5LKeOf2UcDD0qw1fldm6u3iNP unAQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=PJuvLC60; 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=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o5si3231601qkh.166.2020.04.11.09.12.41; Sat, 11 Apr 2020 09:12:56 -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=@kernel.org header.s=default header.b=PJuvLC60; 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=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726596AbgDKQMC (ORCPT + 99 others); Sat, 11 Apr 2020 12:12:02 -0400 Received: from mail.kernel.org ([198.145.29.99]:58758 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726054AbgDKQMC (ORCPT ); Sat, 11 Apr 2020 12:12:02 -0400 Received: from localhost (unknown [213.57.247.131]) (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 708232078E; Sat, 11 Apr 2020 16:12:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1586621522; bh=xGSrZYsmr8Rx4rTlJx8S0cahLkNk3/rISN1e36L5dfw=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=PJuvLC60UfUFZJ6c6uAbd2GfsMnVqppzNcrJkgGE26coDxnU244BVymNHyLFxVvh/ SGVBw4msc7PUOKxizlBOLa+Zn/nyY2mOeFWU/EoNXeoNDBtx/E+f2V7a03X+E0IQLE zchs/QnkHPcr3mObpoAV1v4FVmYW1XFsrDBGjrbw= Date: Sat, 11 Apr 2020 19:11:56 +0300 From: Leon Romanovsky To: Borislav Petkov Cc: "David S. Miller" , Jakub Kicinski , Tom Lendacky , Keyur Chudgar , Don Fry , Veaceslav Falico , Jay Vosburgh , linux-acenic@sunsite.dk, Maxime Ripard , Heiko Stuebner , Mark Einon , Chris Snook , linux-rockchip@lists.infradead.org, Iyappan Subramanian , Igor Russkikh , David Dillow , Netanel Belgazal , Quan Nguyen , Jay Cliburn , Lino Sanfilippo , linux-arm-kernel@lists.infradead.org, Andreas Larsson , Andy Gospodarek , netdev@vger.kernel.org, Thor Thayer , linux-kernel@vger.kernel.org, Ion Badulescu , Arthur Kiyanovski , Jes Sorensen , nios2-dev@lists.rocketboards.org, Chen-Yu Tsai Subject: Re: [PATCH] net/3com/3c515: Fix MODULE_ARCH_VERMAGIC redefinition Message-ID: <20200411161156.GA200683@unreal> References: <20200224085311.460338-1-leon@kernel.org> <20200224085311.460338-4-leon@kernel.org> <20200411155623.GA22175@zn.tnic> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200411155623.GA22175@zn.tnic> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Apr 11, 2020 at 05:56:23PM +0200, Borislav Petkov wrote: > From: Borislav Petkov > > Change the include order so that MODULE_ARCH_VERMAGIC from the arch > header arch/x86/include/asm/module.h gets used instead of the fallback > from include/linux/vermagic.h and thus fix: > > In file included from ./include/linux/module.h:30, > from drivers/net/ethernet/3com/3c515.c:56: > ./arch/x86/include/asm/module.h:73: warning: "MODULE_ARCH_VERMAGIC" redefined > 73 | # define MODULE_ARCH_VERMAGIC MODULE_PROC_FAMILY > | > In file included from drivers/net/ethernet/3com/3c515.c:25: > ./include/linux/vermagic.h:28: note: this is the location of the previous definition > 28 | #define MODULE_ARCH_VERMAGIC "" > | > > Fixes: 6bba2e89a88c ("net/3com: Delete driver and module versions from 3com drivers") > Signed-off-by: Borislav Petkov > --- > drivers/net/ethernet/3com/3c515.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Probably, this is the right change, but I have a feeling that the right solution will be inside headers itself. It is a little bit strange that both very common kernel headers like module.h and vermagic.h are location dependant. Thanks > > diff --git a/drivers/net/ethernet/3com/3c515.c b/drivers/net/ethernet/3com/3c515.c > index 90312fcd6319..cdceef891dbd 100644 > --- a/drivers/net/ethernet/3com/3c515.c > +++ b/drivers/net/ethernet/3com/3c515.c > @@ -22,7 +22,6 @@ > > */ > > -#include > #define DRV_NAME "3c515" > > #define CORKSCREW 1 > @@ -67,6 +66,7 @@ static int max_interrupt_work = 20; > #include > #include > #include > +#include > > #include > #include > -- > 2.21.0 > > -- > Regards/Gruss, > Boris. > > https://people.kernel.org/tglx/notes-about-netiquette