Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp1757080ybp; Fri, 11 Oct 2019 20:41:30 -0700 (PDT) X-Google-Smtp-Source: APXvYqyhkqSNYD9Wuok67JfvRo92+e5Gb4idjyk/ZTxi8d0WvIYbS1cftVP+4yV/33MgvtNfo1n7 X-Received: by 2002:a05:6402:296:: with SMTP id l22mr17035415edv.86.1570851690433; Fri, 11 Oct 2019 20:41:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570851690; cv=none; d=google.com; s=arc-20160816; b=iuMQPVPvRq4Q1HgEUGipYxkyujDjg9NAvzNy68flqDeFj+FKDVLPTX32MEp3GyvwNj OKkle8BZmPUq0Wx23d+l4DJd+Mt8dMy/hQmGtT+OMqvnoSoe0S2hKmiliyrkUf0emTLR J+zvv6R5V/01G59we3foHE0whZxlehNXMJA7ie+J6WGLcXndcZmEMh3SNeup4+kB0XbT GikCBmdG6nKjWbJroDFD/y0RIsBpFr7ha6RpISIa6lpNMOhGZZOWnJsJfmGtT585nEBl bT1Pk3KMJzI8BIdNlNM0J96T0X/L4Kmk4gMhoyyrYL0nue4TMj5QLMWkLMH3UEP82dGC Us0w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature:dkim-filter; bh=WHihSG+Qg/s4+X69FAzzLRuZct3/u+AWzgWTVo2ivT0=; b=gbpkv6ZhCSjXnTavtZcrKAN7HEeRgCpoCMPP3we+TNGRTAOFAJNMyb0FHXc4bYGcho 8Js15B4cnWj9XfBK3m4pZzFliDuK0JN0+ViLtDDvUm6LEpYYzujMwplN/9sHy5SRVgvR 1nTVTbIUU4KRl07dk7lIRb7pgPLXJjSa4Y2EDL/hMAbF0VIrnMu0vWF1nIMnlogkpL/e 3S9yNxACLOsagqA4Gdet1X00rnfNg0fLPzwKAqkr0un2vLM8pJ7fGboLp0RnrKKXHwTt b1ynDTchs+diNswkGfBaOWUGnxwc4YHEiH3wHKe7Y7zlmSdYbtBxfG1aLfrWZMYVCQnG e6QA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=ErnqTykz; 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 t18si6163547eju.329.2019.10.11.20.40.51; Fri, 11 Oct 2019 20:41:30 -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=@nifty.com header.s=dec2015msa header.b=ErnqTykz; 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 S1727507AbfJLDgw (ORCPT + 99 others); Fri, 11 Oct 2019 23:36:52 -0400 Received: from conssluserg-03.nifty.com ([210.131.2.82]:25066 "EHLO conssluserg-03.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726839AbfJLDgv (ORCPT ); Fri, 11 Oct 2019 23:36:51 -0400 Received: from mail-vs1-f44.google.com (mail-vs1-f44.google.com [209.85.217.44]) (authenticated) by conssluserg-03.nifty.com with ESMTP id x9C3aOfV007471; Sat, 12 Oct 2019 12:36:24 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-03.nifty.com x9C3aOfV007471 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1570851385; bh=WHihSG+Qg/s4+X69FAzzLRuZct3/u+AWzgWTVo2ivT0=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=ErnqTykzKfuCwIT+Wdxq5pAE7l5mvAS6+OB6vHyix1pHlxH4gT/rAqjtjU4Kl2hNQ F/3JkvxXfq+b+Ad0vbBqN+hQCuFRL8TWLN4uwo5uR6a5HiPTPUYspZ9rEOWnh2NSWF RfSK+mmqfZxS6oD7UCTiBWfbfocvDOeCHCTsUxrAeM2/uQTtg1Pb+4MdYyOgLPqBEa WiCUUFiDl1kVJp5xXLc3bGy9C9x2q2sXhEOi76Q8bbLVr60AtrXptiHqLrLWbAe7y+ hOXCuZrx/TBLpdbaKWfW6moeoEz0AiUU4hrlBxSvMbSTwAdyo5nwHhjgKs+ADi5BAD Zl/nMR+rBDq5w== X-Nifty-SrcIP: [209.85.217.44] Received: by mail-vs1-f44.google.com with SMTP id b1so7501644vsr.10; Fri, 11 Oct 2019 20:36:24 -0700 (PDT) X-Gm-Message-State: APjAAAXFhH8oVcJ+9nSulKsLtt5AiYpP+d/Y3az16Fy2/2S2e/vzltv7 tOVhd92nMhQealOHv0I1cxq3mdC6PC2SrQCVxDw= X-Received: by 2002:a67:ff86:: with SMTP id v6mr11018051vsq.181.1570851383515; Fri, 11 Oct 2019 20:36:23 -0700 (PDT) MIME-Version: 1.0 References: <20191010151443.7399-1-maennich@google.com> <20191010151443.7399-4-maennich@google.com> In-Reply-To: <20191010151443.7399-4-maennich@google.com> From: Masahiro Yamada Date: Sat, 12 Oct 2019 12:35:47 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 3/4] symbol namespaces: revert to previous __ksymtab name scheme To: Matthias Maennich Cc: Linux Kernel Mailing List , "Cc: Android Kernel" , Jessica Yu , Martijn Coenen , Lucas De Marchi , Shaun Ruffell , Greg Kroah-Hartman , Will Deacon , Linux Kbuild mailing list , linux-modules Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Oct 11, 2019 at 12:16 AM Matthias Maennich wrote: > > The introduction Symbol Namespaces changed the naming schema of the > __ksymtab entries from __kysmtab__symbol to __ksymtab_NAMESPACE.symbol. > > That caused some breakages in tools that depend on the name layout in > either the binaries(vmlinux,*.ko) or in System.map. E.g. kmod's depmod > would not be able to read System.map without a patch to support symbol > namespaces. A warning reported by depmod for namespaced symbols would > look like > > depmod: WARNING: [...]/uas.ko needs unknown symbol usb_stor_adjust_quirks > > In order to address this issue, revert to the original naming scheme and > rather read the __kstrtabns_ entries and their corresponding > values from __ksymtab_strings to update the namespace values for > symbols. After having read all symbols and handled them in > handle_modversions(), the symbols are created. In a second pass, read > the __kstrtabns_ entries and update the namespaces accordingly. > > Suggested-by: Jessica Yu > Fixes: 8651ec01daed ("module: add support for symbol namespaces.") > Signed-off-by: Matthias Maennich According to https://lore.kernel.org/patchwork/patch/1135222/ was this problem reported by Stefan? Reported-by: Stefan Wahren BTW, I initially suggested this way of fixing. Suggested-by: Masahiro Yamada > @@ -74,9 +72,8 @@ struct kernel_symbol { > int namespace_offset; > }; > #else > -#define __KSYMTAB_ENTRY_NS(sym, sec, ns) \ > - static const struct kernel_symbol __ksymtab_##sym##__##ns \ > - asm("__ksymtab_" #ns NS_SEPARATOR #sym) \ For consistency, you could also delete asm("__ksymtab_" #sym) by this patch instead of by 4/4. Not a big deal, though. Reviewed-by: Masahiro Yamada -- Best Regards Masahiro Yamada