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] [day] [month] [year] [list]
Message-ID: <20150327011914.GA1743@sirena.org.uk>
Date:	Thu, 26 Mar 2015 18:19:14 -0700
From:	Mark Brown <broonie@...nel.org>
To:	yakir <ykk@...k-chips.com>
Cc:	Liam Girdwood <lgirdwood@...il.com>, djkurtz@...omium.org,
	dianders@...omium.org, linux-rockchip@...ts.infradead.org,
	David Airlie <airlied@...ux.ie>,
	Philipp Zabel <p.zabel@...gutronix.de>,
	Russell King <rmk+kernel@....linux.org.uk>,
	Andy Yan <andy.yan@...k-chips.com>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Fabio Estevam <fabio.estevam@...escale.com>,
	dri-devel@...ts.freedesktop.org, Jaroslav Kysela <perex@...ex.cz>,
	Takashi Iwai <tiwai@...e.de>,
	Lars-Peter Clausen <lars@...afoo.de>,
	Brian Austin <brian.austin@...rus.com>,
	Bard Liao <bardliao@...ltek.com>,
	Oder Chiou <oder_chiou@...ltek.com>,
	Max Filippov <jcmvbkbc@...il.com>,
	Axel Lin <axel.lin@...ics.com>, Arnd Bergmann <arnd@...db.de>,
	Jyri Sarha <jsarha@...com>, Sean Cross <xobs@...agi.com>,
	Ben Zhang <benzh@...omium.org>, linux-kernel@...r.kernel.org,
	alsa-devel@...a-project.org, mmind00@...glemail.com,
	marcheu@...omium.org, mark.yao@...k-chips.com
Subject: Re: [PATCH v4 14/15] ASoC: rockchip/rockchip-hdmi-audio: add sound
 driver for hdmi audio

On Fri, Mar 27, 2015 at 09:16:17AM +0800, yakir wrote:
> On 2015年03月27日 02:16, Mark Brown wrote:

> >>+free_cpu_of_node:
> >>+	hdmi_audio_dai.cpu_of_node = NULL;
> >>+	hdmi_audio_dai.platform_of_node = NULL;
> >>+free_priv_data:
> >>+	snd_soc_card_set_drvdata(card, NULL);
> >>+	platform_set_drvdata(pdev, NULL);
> >>+	card->dev = NULL;

> >If any of these assignments is doing anything there's a problem with the
> >code.


> Yes, when probe failed, program will goto this code.

You're missing the point, these don't do anything useful.

> >>+{
> >>+	struct snd_soc_card *card = platform_get_drvdata(pdev);
> >>+
> >>+	snd_soc_unregister_card(card);

> >devm_snd_soc_register_card() and you can remove this function entirely.

> do you mean that when I take devm_snd_soc_register_card() to register card,
> then I do not need unregister card any more(destroy with device) ?

Yes, that is the whole point of the devm_ APIs.

Download attachment "signature.asc" of type "application/pgp-signature" (474 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ