]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
ALSA: ctxfi: Add hw parameter to daio_mgr_dao_init()
authorHarin Lee <me@harin.net>
Mon, 24 Nov 2025 18:04:56 +0000 (03:04 +0900)
committerTakashi Iwai <tiwai@suse.de>
Tue, 25 Nov 2025 07:02:15 +0000 (08:02 +0100)
Add a hw parameter to the daio_mgr_dao_init() function to provide
access to model-specific information. This is necessary for proper
configuration of S/PDIF and I2S output ports on different hardware
variants.

Signed-off-by: Harin Lee <me@harin.net>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Link: https://patch.msgid.link/20251124180501.2760421-2-me@harin.net
sound/pci/ctxfi/ctdaio.c
sound/pci/ctxfi/cthardware.h
sound/pci/ctxfi/cthw20k1.c
sound/pci/ctxfi/cthw20k2.c

index c0c3f8ab84677daef95d60d6a56a64216eb47fec..10d0a7088718a8e1222163e9e29f81085f394ec1 100644 (file)
@@ -390,7 +390,7 @@ static int dao_rsc_init(struct dao *dao,
        hw->daio_mgr_commit_write(hw, mgr->mgr.ctrl_blk);
 
        conf = (desc->msr & 0x7) | (desc->passthru << 3);
-       hw->daio_mgr_dao_init(mgr->mgr.ctrl_blk,
+       hw->daio_mgr_dao_init(hw, mgr->mgr.ctrl_blk,
                        daio_device_index(dao->daio.type, hw), conf);
        hw->daio_mgr_enb_dao(mgr->mgr.ctrl_blk,
                        daio_device_index(dao->daio.type, hw));
index 2875cec83b8f24a18f2a2e09cc5cab9b01714d1f..d29b4e5b3fcc4fd951d855ebd4a31802571140d9 100644 (file)
@@ -167,7 +167,7 @@ struct hw {
        int (*daio_mgr_dsb_dai)(void *blk, unsigned int idx);
        int (*daio_mgr_enb_dao)(void *blk, unsigned int idx);
        int (*daio_mgr_dsb_dao)(void *blk, unsigned int idx);
-       int (*daio_mgr_dao_init)(void *blk, unsigned int idx,
+       int (*daio_mgr_dao_init)(struct hw *hw, void *blk, unsigned int idx,
                                                unsigned int conf);
        int (*daio_mgr_set_imaparc)(void *blk, unsigned int slot);
        int (*daio_mgr_set_imapnxt)(void *blk, unsigned int next);
index 42b90c9b2ee9f12026c25eb7747762aa6bc1aa88..60cc1d14453a4bc25cd64391cdbc13ebf82f8c67 100644 (file)
@@ -1031,7 +1031,7 @@ static int daio_mgr_dsb_dao(void *blk, unsigned int idx)
        return 0;
 }
 
-static int daio_mgr_dao_init(void *blk, unsigned int idx, unsigned int conf)
+static int daio_mgr_dao_init(struct hw *hw __maybe_unused, void *blk, unsigned int idx, unsigned int conf)
 {
        struct daio_mgr_ctrl_blk *ctl = blk;
 
index 55af8ef29838366d38f74840f6419066b1d89633..1a085e7e57869b68fb64c85c90882704830afaf9 100644 (file)
@@ -985,7 +985,7 @@ static int daio_mgr_dsb_dao(void *blk, unsigned int idx)
        return 0;
 }
 
-static int daio_mgr_dao_init(void *blk, unsigned int idx, unsigned int conf)
+static int daio_mgr_dao_init(struct hw *hw __maybe_unused, void *blk, unsigned int idx, unsigned int conf)
 {
        struct daio_mgr_ctrl_blk *ctl = blk;