Re: [PATCH 7/7] remoteproc: Add custom STE-modem firmware loader.

From: Ohad Ben-Cohen
Date: Mon Jun 11 2012 - 06:07:02 EST


Hi Sjur,

On Mon, Jun 11, 2012 at 12:55 PM, Sjur Brændeland
<sjur.brandeland@xxxxxxxxxxxxxx> wrote:
> How about this:
> In rproc_alloc, we set the rproc_elf_fw_ops as default
...
> Then the file remoteproc_elf_loader.c containing rproc_elf_fw_ops is
> default fw_ops
> and is contained remoteproc.ko.
>
> The ste_modem_fw_ops will be linked together with the ste_modem_rproc module,
> and none of the fw_ops needs to be exported as symbols globally.

All of the above sounds very good to me.

>, and we add a function:
>
> void rproc_set_fw_ops(struct rproc *rproc, const struct rproc_fw_ops *fw_ops)
> {
>        rproc->fw_ops = fw_ops;
> }
> EXPORT_SYMBOL(rproc_set_fw_ops);

I'm just not sure about this part.

If we're going to have the STE fw ops linked together with the STE
module (which sounds really good btw), can the STE module just
directly do

rproc->fw_ops = ste_modem_fw_ops;

before calling rproc_register() ?

This way we're not exposing any other symbol, and things look pretty
clean and simple.

Thanks,
Ohad.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/