lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZJLX/fPM1FbBxM2X@matsya>
Date:   Wed, 21 Jun 2023 16:29:09 +0530
From:   Vinod Koul <vkoul@...nel.org>
To:     Pierre-Louis Bossart <pierre-louis.bossart@...ux.intel.com>
Cc:     Bard Liao <yung-chuan.liao@...ux.intel.com>,
        alsa-devel@...a-project.org, linux-kernel@...r.kernel.org,
        bard.liao@...el.com
Subject: Re: [PATCH 3/4] soundwire: extend parameters of
 new_peripheral_assigned() callback

On 08-06-23, 08:24, Pierre-Louis Bossart wrote:
> 
> >> -static void generic_new_peripheral_assigned(struct sdw_bus *bus, int dev_num)
> >> +static void generic_new_peripheral_assigned(struct sdw_bus *bus,
> >> +					    struct sdw_slave *slave,
> >> +					    int dev_num)
> >>  {
> >>  	struct sdw_cdns *cdns = bus_to_cdns(bus);
> >>  	struct sdw_intel *sdw = cdns_to_intel(cdns);
> >> diff --git a/include/linux/soundwire/sdw.h b/include/linux/soundwire/sdw.h
> >> index 8a7541ac735e..41a856bedf1e 100644
> >> --- a/include/linux/soundwire/sdw.h
> >> +++ b/include/linux/soundwire/sdw.h
> >> @@ -861,7 +861,9 @@ struct sdw_master_ops {
> >>  	int (*pre_bank_switch)(struct sdw_bus *bus);
> >>  	int (*post_bank_switch)(struct sdw_bus *bus);
> >>  	u32 (*read_ping_status)(struct sdw_bus *bus);
> >> -	void (*new_peripheral_assigned)(struct sdw_bus *bus, int dev_num);
> >> +	void (*new_peripheral_assigned)(struct sdw_bus *bus,
> >> +					struct sdw_slave *slave,
> > 
> > maybe better, drop the bus and pass slave (which contains bus)
> 
> I kept it for consistency, all callbacks for sdw_master_ops start with
> the bus parameter.

That is a valid point, since this is sdw_master_ops() and not slave,
this looks better

-- 
~Vinod

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ