Linux Serial subsystem development
 help / color / mirror / Atom feed
From: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
To: Serge Semin <fancer.lancer@gmail.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Jiri Slaby <jirislaby@kernel.org>, Arnd Bergmann <arnd@arndb.de>,
	Jiaxun Yang <jiaxun.yang@flygoat.com>,
	Alexey Malahov <Alexey.Malahov@baikalelectronics.ru>,
	Stephen Rothwell <sfr@rothwell.id.au>,
	Andrew Morton <akpm@linux-foundation.org>,
	linux-mips@vger.kernel.org, linux-serial@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/4] mips: cm: Add CM GCR and L2-sync base address getters declarations
Date: Tue, 20 Feb 2024 18:24:25 +0100	[thread overview]
Message-ID: <ZdTgSZRTDkakekkd@alpha.franken.de> (raw)
In-Reply-To: <20240215171740.14550-3-fancer.lancer@gmail.com>

On Thu, Feb 15, 2024 at 08:17:27PM +0300, Serge Semin wrote:
> Based on the design pattern utilized in the CM GCR and L2-sync base
> address getters implementation the platform-specific code is capable to
> re-define the getters and re-use the weakly defined initial versions. But
> since the re-definition is supposed to be done in another source file the
> interface methods have been globally defined which in its turn causes the
> "no previous prototype" warning printed should the re-definition is
> finally introduced. Since without the global declarations the pattern can
> be considered as incomplete and causing the warning printed, fix it by
> providing the respective methods prototype declarations in
> "arch/mips/include/asm/mips-cm.h".
> 
> Signed-off-by: Serge Semin <fancer.lancer@gmail.com>
> 
> ---
> 
> Note as I mentioned in the previous patch, since the weak implementation
> of the getters isn't utilized other than as a default implementation of
> the original methods, we can convert the denoted pattern to a simple
> __weak attributed methods. Let me know if that would be more preferable.

how about simply remove __mips_cm_l2sync_phys_base() and do everything
via mips_cm_phys_base(). And at the moment without anyone overriding
mips_cm_phys_base I tend to keep static without __weak. If someone
needs, we can change it. Does this make sense ?

Thomas.

-- 
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea.                                                [ RFC1925, 2.3 ]

  reply	other threads:[~2024-02-20 17:24 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-15 17:17 [PATCH 0/4] MIPS: Fix missing proto and passing arg warnings Serge Semin
2024-02-15 17:17 ` [PATCH 1/4] mips: cm: Add __mips_cm_l2sync_phys_base prototype declaration Serge Semin
2024-03-11 22:26   ` Andy Shevchenko
2024-02-15 17:17 ` [PATCH 2/4] mips: cm: Add CM GCR and L2-sync base address getters declarations Serge Semin
2024-02-20 17:24   ` Thomas Bogendoerfer [this message]
2024-02-21 18:39     ` Serge Semin
2024-02-23  9:06       ` Thomas Bogendoerfer
2024-02-23 10:38         ` Serge Semin
2024-02-15 17:17 ` [PATCH 3/4] mips: zboot: Fix "no previous prototype" build warning Serge Semin
2024-02-23  9:18   ` Thomas Bogendoerfer
2024-02-15 17:17 ` [PATCH 4/4] tty: mips_ejtag_fdc: Fix passing incompatible pointer type warning Serge Semin
2024-02-16  5:51   ` Jiri Slaby
2024-02-16 14:12     ` Serge Semin
2024-02-23  9:18   ` Thomas Bogendoerfer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZdTgSZRTDkakekkd@alpha.franken.de \
    --to=tsbogend@alpha.franken.de \
    --cc=Alexey.Malahov@baikalelectronics.ru \
    --cc=akpm@linux-foundation.org \
    --cc=arnd@arndb.de \
    --cc=fancer.lancer@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=jiaxun.yang@flygoat.com \
    --cc=jirislaby@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mips@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=sfr@rothwell.id.au \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox