lkml.org 
[lkml]   [2020]   [Dec]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH 04/14] mfd: arizona: Allow building arizona MFD-core as module
    On Sun, Dec 27, 2020 at 10:12:22PM +0100, Hans de Goede wrote:
    > There is no reason why the arizona core,irq and codec model specific
    > regmap bits cannot be build as a module. All they do is export symbols
    > which are used by the arizona-spi and/or arizona-i2c modules, which
    > themselves can be built as module.
    >
    > Change the Kconfig and Makefile arizona bits so that the arizona MFD-core
    > can be built as a module.
    >
    > This is especially useful on x86 platforms with a WM5102 codec, this
    > allows the arizona MFD driver necessary for the WM5102 codec to be
    > enabled in generic distro-kernels without growing the base kernel-image
    > size.
    >
    > Signed-off-by: Hans de Goede <hdegoede@redhat.com>
    > ---

    I think this patch might still cause some issues. ASoC has an
    idiom where the machine driver does a select on the necessary
    CODEC drivers. Select doesn't take care of dependencies etc. So I
    believe if you build the machine driver as built in, it then
    selects the CODEC as built in. If you have the MFD as a module
    the build then fails due to the the CODEC calling some Arizona
    functions.

    arizona_request_irq, arizona_free_irq, arizona_set_irq_wake

    On Madera we made the equivalents inline functions to avoid the
    issue, the same should work here.

    include/linux/irqchip/irq-madera.h

    Thanks,
    Charles

    \
     
     \ /
      Last update: 2020-12-29 13:02    [W:4.697 / U:0.008 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site