From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id BEA64C83F16 for ; Thu, 29 Aug 2024 13:15:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:In-Reply-To: Content-Type:MIME-Version:References:Message-ID:Subject:To:Date:From:Reply-To :Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=zcevrydr3wb+wZ7r5tLJWsjj7JW9bLBAqf2EeUSSlJQ=; b=eO2bqH2Jfx/88RssMvChagQqU0 N/4CmPo67O9pmmlwJH+29k4Gi1ClVGrl2LeqZ1gh9x93c4jqRTmuTG1cjHHisTcARRib1zOw2jrbh 7m8hXahwiAWl0HcauXsYHMuH/XdwaEzXRJHKpIn/pacCsoRt3ou4MXOZeE0KRsEIZwa2tMX6rTcZP TFkoGvVcMCZdmyCpFzfhPm2YjR2+AM2MTVYIrybygQgNwcIR+4mOIKKBbokXny3k2TEjZXy2/IcJI BJo3fC/D1DZVOhRjpx5+kdcZu7EXDR4k5RBPYwJV9mqdvAY+ak6oH+AJ5cF2iH1V2Jrrg1UUPZQG9 /9nGGJAQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sjezo-000000026wH-1vWF; Thu, 29 Aug 2024 13:15:28 +0000 Received: from mail-lf1-x130.google.com ([2a00:1450:4864:20::130]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sjexr-000000026Ml-3MaQ for linux-arm-kernel@lists.infradead.org; Thu, 29 Aug 2024 13:13:29 +0000 Received: by mail-lf1-x130.google.com with SMTP id 2adb3069b0e04-5343617fdddso1156881e87.0 for ; Thu, 29 Aug 2024 06:13:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=google; t=1724937206; x=1725542006; darn=lists.infradead.org; h=in-reply-to:content-disposition:mime-version:references :mail-followup-to:message-id:subject:cc:to:date:from:from:to:cc :subject:date:message-id:reply-to; bh=zcevrydr3wb+wZ7r5tLJWsjj7JW9bLBAqf2EeUSSlJQ=; b=XC6AdLtS+vFCSKbmTntV5+otJqrqeX1M97+E09JKiFmBmOCPJNbCYyi/RwBBdHUdzg pfIHkPcSSQdULt5PBpxqUuZXGmndem4y5ZydUaj5KxXal7wD5yLDaKz7WQcPW19GjR2E XL6SOz+OUVQFY0A4DaNVrnpUjOFNVRbzLYe+dtuRZj92YNGLORAmlI02zbkpMBNJeTPA YJwKpMZFa/a+oD6wbthZ9Yz4F/G8cGJUJhaYdW2JmJDXf5yCBT3k88EQGOTpgGQbFqzo fWTIfw24R1pUn9vkIo8l/nYrM2tvilkI9C2uZ2BhwJHh0hOVY2GVHFtI09RNfhFm7P+z TOmA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724937206; x=1725542006; h=in-reply-to:content-disposition:mime-version:references :mail-followup-to:message-id:subject:cc:to:date:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=zcevrydr3wb+wZ7r5tLJWsjj7JW9bLBAqf2EeUSSlJQ=; b=Dkn6ozmq6CFewpnOQOcvoKC4W3bT/h4D8yuG/dGpXnDtC7imt38y86aYTl70jgt2Qp BEUx00ykk6Aao8OCdjivf7mir4WmxfME3GmBAr7xKInB2wdsSydjYHczBi0KnJjIoj40 X+LnoysyEU5Xx/6FrzWj51ptH2Yecb2I8SLdx5ddqtc9KAnHRdlJzzt8oZkR38LoU4T5 0/Gl3LG6Qf0ISMCw2hDkxYwomT22fF20I99cP5lh146zSrDKhsG3xi0dlWlHDce53IVc cUF/Qp6hMpbAxcti9F+zJ9xAwNgaUSPGybyR/oT2vC9KHm/P9UZ5YMDvNpgK7YwZRbBa n79g== X-Forwarded-Encrypted: i=1; AJvYcCUxb97y51pKmsjxIKC+Nv2QMXQAoG0t/WTNsfwFjFY6YM9TVcgQUknODWccp/EQf2Xc7aZ+pp0x2FdejXcrrh1y@lists.infradead.org X-Gm-Message-State: AOJu0YxTm/fx5Q414dlglZFpaJmP1fgulPQ3jdFBS6+xWbuUzHMueZw3 yCpEJZiIZ6FpigAvyL4lg71XJ3JgI96XFIzZyIP32Gpq8D+CjjqUBIPYdXNvHps= X-Google-Smtp-Source: AGHT+IFLMk4m6y7fSkfLg3A3IXASRJuXYrAbPU9+Ww0KPnYO42UsA+Qqa5Bo9AeJfKaUmIGFU/dvxw== X-Received: by 2002:a05:6512:3b9e:b0:52c:cd77:fe03 with SMTP id 2adb3069b0e04-5353e54d499mr2408631e87.14.1724937205212; Thu, 29 Aug 2024 06:13:25 -0700 (PDT) Received: from localhost (host-80-182-198-72.pool80182.interbusiness.it. [80.182.198.72]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-5c226ce4f5dsm697741a12.89.2024.08.29.06.13.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 29 Aug 2024 06:13:24 -0700 (PDT) From: Andrea della Porta X-Google-Original-From: Andrea della Porta Date: Thu, 29 Aug 2024 15:13:31 +0200 To: Andrew Lunn Subject: Re: [PATCH 00/11] Add support for RaspberryPi RP1 PCI device using a DT overlay Message-ID: Mail-Followup-To: Andrew Lunn , Krzysztof Kozlowski , Andrea della Porta , Michael Turquette , Stephen Boyd , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Florian Fainelli , Broadcom internal kernel review list , Linus Walleij , Catalin Marinas , Will Deacon , Derek Kiernan , Dragan Cvetic , Arnd Bergmann , Greg Kroah-Hartman , Nicolas Ferre , Claudiu Beznea , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Saravana Kannan , Bjorn Helgaas , linux-clk@vger.kernel.org, devicetree@vger.kernel.org, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org, netdev@vger.kernel.org, linux-pci@vger.kernel.org, linux-arch@vger.kernel.org, Lee Jones , Stefan Wahren References: <14990d25-40a2-46c0-bf94-25800f379a30@kernel.org> <45a41ed9-2e42-4fd5-a1d5-35de93ce0512@lunn.ch> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240829_061327_898003_981022C6 X-CRM114-Status: GOOD ( 25.61 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Catalin Marinas , Michael Turquette , Claudiu Beznea , Eric Dumazet , Dragan Cvetic , Will Deacon , linux-clk@vger.kernel.org, linux-arch@vger.kernel.org, Rob Herring , Florian Fainelli , Lee Jones , Krzysztof Kozlowski , Saravana Kannan , Broadcom internal kernel review list , linux-pci@vger.kernel.org, Jakub Kicinski , Paolo Abeni , Linus Walleij , devicetree@vger.kernel.org, Conor Dooley , Arnd Bergmann , linux-gpio@vger.kernel.org, linux-rpi-kernel@lists.infradead.org, Bjorn Helgaas , Andrea della Porta , linux-arm-kernel@lists.infradead.org, Derek Kiernan , Stephen Boyd , Greg Kroah-Hartman , linux-kernel@vger.kernel.org, Stefan Wahren , netdev@vger.kernel.org, Krzysztof Kozlowski , "David S. Miller" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi Andrew, On 15:04 Thu 29 Aug , Andrew Lunn wrote: > > > > WARNING: externs should be avoided in .c files > > > > #331: FILE: drivers/misc/rp1/rp1-pci.c:58: > > > > +extern char __dtbo_rp1_pci_begin[]; > > > > > > > > True, but in this case we don't have a symbol that should be exported to other > > > > translation units, it just needs to be referenced inside the driver and > > > > consumed locally. Hence it would be better to place the extern in .c file. > > > > > > Did you try making it static. > > > > The dtso is compiled into an obj and linked with the driver which is in > > a different transaltion unit. I'm not aware on other ways to include that > > symbol without declaring it extern (the exception being some hackery > > trick that compile the dtso into a .c file to be included into the driver > > main source file). > > Or probably I'm not seeing what you are proposing, could you please elaborate > > on that? > > Sorry, i jumped to the wrong conclusion. Often it is missing static > keyword which causes warnings. However, you say it needs to be global > scope. > > Reading the warning again: > > > > > WARNING: externs should be avoided in .c files > > It is wanting you to put it in a .h file, which then gets > included by the two users. Ah I see now what you were referring to, thanks. I'll put the extern into an header file, although there are no two users of that, the only one being rp1-pci.c. Many thanks, Andrea > > Andrew