mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Masahiro Yamada <masahiroy@kernel.org>
To: Sascha Hauer <s.hauer@pengutronix.de>
Cc: Barebox List <barebox@lists.infradead.org>,
	David Dgien <dgienda125@gmail.com>
Subject: Re: [RFC PATCH 0/8] Module and ARM Module updates and fixes
Date: Tue, 23 Jun 2020 02:52:29 +0900	[thread overview]
Message-ID: <CAK7LNAS7mQOcwmjiMo9HbU=4SUiPywES1TDfEWOwQcu+VaTFvg@mail.gmail.com> (raw)
In-Reply-To: <20200618131017.GJ11869@pengutronix.de>

On Thu, Jun 18, 2020 at 10:10 PM Sascha Hauer <s.hauer@pengutronix.de> wrote:
>
> On Wed, Jun 17, 2020 at 09:54:55PM -0400, David Dgien wrote:
> > Hi Sascha,
> >
> > On Wed, Jun 17, 2020 at 03:45:38PM +0200, Sascha Hauer wrote:
> > > Hi David,
> > >
> > > On Tue, Jun 16, 2020 at 11:43:56PM -0400, David Dgien wrote:
> > > > This series fixes various bugs and bit-rot issues with the module
> > > > loading code. It also ports a couple of modules features from the Linux
> > > > kernel: arch specific section fixups, and module PLTs for ARM modules,
> > > > to contain veneers for 'bl' instructions.
> > > >
> > > > There are two things in this series I'm looking for feedback on:
> > > > Linux implements module_frob_arch_sections as a weak symbol for the
> > > > default case. I didn't see any other "weak" functions in barebox, so I
> > > > wasn't sure if using that was acceptable.
> > >
> > > For things that are really mutually exclusive like different
> > > implementations on different architectures I think weak functions are
> > > ok. They are not ok as a quick hack for hooking something into something
> > > though.
> > >
> >
> > I'll make the change to a weak function here in a v2, since it will be a
> > bit cleaner.
> >
> > > > Since the Kconfig
> > > > HAVE_MOD_ARCH_SPECIFIC already exists as part of the change, I just used
> > > > that to define a static inline default implementation, but using a weak
> > > > function would make that slightly cleaner.
> > > >
> > > > And in the patch that added the init macros to module.h, I wasn't sure
> > > > if it would be okay to pollute init.h with the #ifndef MODULE
> > > > directives, so instead I just #undef'd all of the initcalls before
> > > > redefining them in module.h.  If it's okay to add the #ifndef MODULE to
> > > > init.h, that would be significantly cleaner than the current
> > > > implementation.
> > >
> > > I think it's ok to add #ifndef MODULE to init.h
> >
> > Same as above.
> >
> > >
> > > Anyway, what do you need modules for? Do you have a good reason or is it
> > > just for the fun of it?
> >
> > I'm working on a project that wants to use barebox as a very lightweight
> > OS replacement.
> > We're using modules to allow loading user code with
> > controlled access to hw interfaces via exported driver symbols.
>
> So barebOS again, we had that as an April fools joke once :)
>
> You'll probably miss things like interrupts, paging and multitasking
> very soon.
>
> Sascha


Does it make sense to choose y/m
depending on how often they are used?

- commands and drivers that are used quite often   ->  built-in
- commands and drivers that are sometimes used     ->  modules



-- 
Best Regards
Masahiro Yamada

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

      reply	other threads:[~2020-06-22 17:53 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-17  3:43 David Dgien
2020-06-17  3:43 ` [RFC PATCH 1/8] Makefile: Initialize and export KBUILD variables David Dgien
2020-06-17  3:43 ` [RFC PATCH 2/8] module: Add init macros to module.h David Dgien
2020-06-17  3:43 ` [RFC PATCH 3/8] module: Fix adding module to list after layout David Dgien
2020-06-17  3:44 ` [RFC PATCH 4/8] module: Fix module command registration David Dgien
2020-06-17  3:44 ` [RFC PATCH 5/8] module: Implement HAVE_MOD_ARCH_SPECIFIC David Dgien
2020-06-17  3:44 ` [RFC PATCH 6/8] arm: makefile: Fix compiler flag variable David Dgien
2020-06-17  3:44 ` [RFC PATCH 7/8] arm: elf: Add THM relocation types David Dgien
2020-06-17  3:44 ` [RFC PATCH 8/8] arm: module: Allow modules outside of bl range David Dgien
2020-06-17 13:52   ` Sascha Hauer
2020-06-17 13:45 ` [RFC PATCH 0/8] Module and ARM Module updates and fixes Sascha Hauer
2020-06-18  1:54   ` David Dgien
2020-06-18 13:10     ` Sascha Hauer
2020-06-22 17:52       ` Masahiro Yamada [this message]

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='CAK7LNAS7mQOcwmjiMo9HbU=4SUiPywES1TDfEWOwQcu+VaTFvg@mail.gmail.com' \
    --to=masahiroy@kernel.org \
    --cc=barebox@lists.infradead.org \
    --cc=dgienda125@gmail.com \
    --cc=s.hauer@pengutronix.de \
    /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