Received: by 2002:a25:d7c1:0:0:0:0:0 with SMTP id o184csp3513303ybg; Mon, 28 Oct 2019 14:08:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqxiUvqtD/WeSsfvprxMccdxxqUzYm7ToQcphaTAfAHwWeHoiIh9Cg5dx1ow/PBCO4+MOuY5 X-Received: by 2002:a17:906:e82:: with SMTP id p2mr18451270ejf.237.1572296925606; Mon, 28 Oct 2019 14:08:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1572296925; cv=none; d=google.com; s=arc-20160816; b=VKWzaFvMBTWtZaWA6ocyX47lmCm8NecRWVTSD0A9BCT/HyXGWheR0WRej+NvbTca8a QD3KWm0LA5HuOmBwH8g+9Rt5+s9dEud0/+g6IQDvbKbXvTnl8SDHg2dS8no0Jo+Jvkdu ej/W2MvcpjYoRMaShVB7j9CFrRGrPYzmzW1A3i6vN6dASGt/XaAwtm3C1Zxa5B+SzHcG 2KOJFV55s9CUld/Ccg0e52Sn4/bGc6X/eiq7i8OG7MVIIVnIK+WkYQ0CB7VzBtroye62 iXIT5oqed4NtSWlOF4lJlHMk8cSQMeLRkuX4t10l0CXVrvqRS5Hv6xE2ikob+5PZGqUN tmlw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature; bh=OeZg6ccyQRixFcnPDplU/iPP4qrcTDMvgUVMOr9o9I0=; b=Dwi+w+sWMXv7uC7w5wL2Qav838H46Lpu3d/nzbBalQ5ZjBQNsv4wOQRLkLyIH5vwUg 26k6VL86JOsafTT39s7ACp9M2yW36Ny6QZ0cRnAsSlq3Yk3ZriDdgin89N5BTLNR1O3m oxLtOraJbtBtZBvba9+KQWsGQIjz++zX1PaTcDShuwdFJ+9CC+z4/HHe716pd6DRaiiO O5WMGclqb98AxmPF0qkKw1Uc02+vMsJVEMzT9Cb9/8NCTLv8bg18mNvPVq/SF+eecKrW E8f1jD1YRzAkQuC4ux/u/6jaRn2IudFZq2ihO80Mov/kA6pQ+O9MknFfHLXSwf3at5Ag xYSg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="0/71qSPo"; 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 d7si8730353eda.429.2019.10.28.14.08.21; Mon, 28 Oct 2019 14:08:45 -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="0/71qSPo"; 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 S1730093AbfJ1POh (ORCPT + 99 others); Mon, 28 Oct 2019 11:14:37 -0400 Received: from mail.kernel.org ([198.145.29.99]:48594 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726196AbfJ1POh (ORCPT ); Mon, 28 Oct 2019 11:14:37 -0400 Received: from linux-8ccs.suse.cz (charybdis-ext.suse.de [195.135.221.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id A5F8B21783; Mon, 28 Oct 2019 15:14:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1572275676; bh=nUTEiVlB+AB4XpfbHMHrrllVK8vtgQ53OJnISc/LqWQ=; h=From:To:Cc:Subject:Date:From; b=0/71qSPom2ZVo56OMnqnKMuu3BVfQbY7fERV6uVinVImk1go7rk+Y/wGs64h250EK m6L7qDmMdWN548X4C/5S5+0skHeDI+ex5TDSO/LbREb2xzN+n5uVrdN9KRYnl42mAt /23cNMdtwubQMwjq3ghtgl/8H6vnbggmxt4vz2eA= From: Jessica Yu To: linux-kernel@vger.kernel.org Cc: Matthias Maennich , Masahiro Yamada , Jessica Yu Subject: [PATCH 1/4] scripts/nsdeps: use $MODORDER to obtain correct modules.order path Date: Mon, 28 Oct 2019 16:14:24 +0100 Message-Id: <20191028151427.31612-1-jeyu@kernel.org> X-Mailer: git-send-email 2.16.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The nsdeps script calls generate_deps() for every module in the modules.order file. It prepends $objtree to obtain the full path of the top-level modules.order file. This produces incorrect results when calling nsdeps for an external module, as only the ns dependencies for in-tree modules listed in $objtree/modules.order are generated rather than the ns dependencies for the external module. To fix this, just use the MODORDER variable provided by kbuild - it uses the correct path for the relevant modules.order file (either in-tree or the one produced by the external module build). Signed-off-by: Jessica Yu --- So, not being too familiar with kbuild, I am not sure if MODORDER was the appropriate kbuild variable to use, but I could not find anything else that gives us the modules.order path. Masahiro, please let me know if this is appropriate usage. scripts/nsdeps | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/nsdeps b/scripts/nsdeps index dda6fbac016e..54d2ab8f9e5c 100644 --- a/scripts/nsdeps +++ b/scripts/nsdeps @@ -52,7 +52,7 @@ generate_deps() { done } -for f in `cat $objtree/modules.order`; do +for f in `cat $MODORDER`; do generate_deps $f done -- 2.16.4