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: <s5hmvrgg3cd.wl-tiwai@suse.de>
Date:	Thu, 04 Feb 2016 11:46:42 +0100
From:	Takashi Iwai <tiwai@...e.de>
To:	"Mauro Carvalho Chehab" <mchehab@....samsung.com>
Cc:	"Shuah Khan" <shuahkh@....samsung.com>, <geliangtang@....com>,
	<alsa-devel@...a-project.org>, <arnd@...db.de>,
	<ricard.wanderlof@...s.com>, <hans.verkuil@...co.com>,
	<labbott@...oraproject.org>, <chehabrafael@...il.com>,
	<klock.android@...il.com>, <misterpib@...il.com>,
	<prabhakar.csengg@...il.com>, <ricardo.ribalda@...il.com>,
	<ruchandani.tina@...il.com>, <takamichiho@...il.com>,
	<tvboxspy@...il.com>, <dominic.sacre@....de>,
	<laurent.pinchart@...asonboard.com>, <crope@....fi>,
	<julian@...st.de>, <clemens@...isch.de>,
	<pierre-louis.bossart@...ux.intel.com>,
	<sakari.ailus@...ux.intel.com>, <corbet@....net>,
	<joe@...po.co.uk>, <johan@...ud.se>, <dan.carpenter@...cle.com>,
	<pawel@...iak.com>, <javier@....samsung.com>,
	<p.zabel@...gutronix.de>, <perex@...ex.cz>,
	<stefanr@...6.in-berlin.de>, <inki.dae@...sung.com>,
	<j.anaszewski@...sung.com>, <jh1009.sung@...sung.com>,
	<k.kozlowski@...sung.com>, <kyungmin.park@...sung.com>,
	<m.szyprowski@...sung.com>, <nenggun.kim@...sung.com>,
	<sw0312.kim@...sung.com>, <elfring@...rs.sourceforge.net>,
	<linux-api@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
	<linux-media@...r.kernel.org>, <linuxbugs@...tgam.net>,
	<gtmkramer@...all.nl>, <normalperson@...t.net>, <daniel@...que.org>
Subject: Re: [PATCH v2 21/22] sound/usb: Use Media Controller API to share media resources

On Thu, 04 Feb 2016 11:36:00 +0100,
Mauro Carvalho Chehab wrote:
> 
> > diff --git a/sound/usb/card.h b/sound/usb/card.h
> > index 71778ca..c15a03c 100644
> > --- a/sound/usb/card.h
> > +++ b/sound/usb/card.h
> > @@ -156,6 +156,7 @@ struct snd_usb_substream {
> >  	} dsd_dop;
> >  
> >  	bool trigger_tstamp_pending_update; /* trigger timestamp being updated from initial estimate */
> > +	void *media_ctl;
> >  };
> 
> This is Takashi's call, but I would prefer to avoid using a void *
> here. Fortunately, GCC is smart enough to handle struct pointers
> even if the header doesn't have a full declaration of the struct.
> 
> So, I would change the above to:
> 
> struct media_device;
> 
> struct snd_usb_substream {
> ...
> 	struct media_device *media_ctl;
> };
> 
> This way, we ensure strong typecast checks when compiling the code under
> sound/usb/media.c, while not needing to include media_device.h header here.

Agreed, this is no big merit to make it a void pointer.


Takashi

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ