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]
Date:	Thu, 04 Dec 2014 00:04:37 +0800
From:	Andy Yan <andy.yan@...k-chips.com>
To:	Russell King - ARM Linux <linux@....linux.org.uk>
CC:	airlied@...ux.ie, Philipp Zabel <p.zabel@...gutronix.de>,
	heiko@...ech.de, fabio.estevam@...escale.com,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Grant Likely <grant.likely@...aro.org>,
	Rob Herring <robh+dt@...nel.org>,
	Shawn Guo <shawn.guo@...aro.org>,
	Josh Boyer <jwboyer@...hat.com>,
	Sean Paul <seanpaul@...omium.org>,
	Inki Dae <inki.dae@...sung.com>,
	Dave Airlie <airlied@...hat.com>,
	Arnd Bergmann <arnd@...db.de>,
	Lucas Stach <l.stach@...gutronix.de>,
	Zubair.Kakakhel@...tec.com, djkurtz@...gle.com, ykk@...k-chips.com,
	linux-kernel@...r.kernel.org, dri-devel@...ts.freedesktop.org,
	devel@...verdev.osuosl.org, devicetree@...r.kernel.org,
	linux-rockchip@...ts.infradead.org, jay.xu@...k-chips.com,
	Pawel Moll <pawel.moll@....com>, mark.yao@...k-chips.com,
	Mark Rutland <mark.rutland@....com>,
	Ian Campbell <ijc+devicetree@...lion.org.uk>,
	vladimir_zapolskiy@...tor.com, Kumar Gala <galak@...eaurora.org>
Subject: Re: [PATCH v16 03/12] drm: imx: imx-hdmi: convert imx-hdmi to drm_bridge
 mode

Hi Russell:

On 2014年12月03日 23:38, Russell King - ARM Linux wrote:
> On Wed, Dec 03, 2014 at 11:29:26PM +0800, Andy Yan wrote:
>> +int imx_hdmi_bind(struct device *dev, struct device *master,
>> +		  void *data, struct drm_encoder *encoder,
>> +		  const struct imx_hdmi_plat_data *plat_data)
>>   {
>>   	struct platform_device *pdev = to_platform_device(dev);
>> -	const struct of_device_id *of_id =
>> -				of_match_device(imx_hdmi_dt_ids, dev);
>>   	struct drm_device *drm = data;
>>   	struct device_node *np = dev->of_node;
>>   	struct device_node *ddc_node;
>> @@ -1594,19 +1566,16 @@ static int imx_hdmi_bind(struct device *dev, struct device *master, void *data)
>>   	struct resource *iores;
>>   	int ret, irq;
>>   
>> -	hdmi = devm_kzalloc(dev, sizeof(*hdmi), GFP_KERNEL);
>> +	hdmi = devm_kzalloc(&pdev->dev, sizeof(*hdmi), GFP_KERNEL);
>>   	if (!hdmi)
>>   		return -ENOMEM;
>>   
>> -	hdmi->dev = dev;
>> +	hdmi->plat_data = plat_data;
>> +	hdmi->dev = &pdev->dev;
>> +	hdmi->dev_type = plat_data->dev_type;
>>   	hdmi->sample_rate = 48000;
>>   	hdmi->ratio = 100;
>> -
>> -	if (of_id) {
>> -		const struct platform_device_id *device_id = of_id->data;
>> -
>> -		hdmi->dev_type = device_id->driver_data;
>> -	}
>> +	hdmi->encoder = encoder;
> I'd suggest changing imx_hdmi_bind() to take the struct resource and irq
> number, and avoiding the platform device stuff altogether in here.
>
    Actually this is what the current code do: the resource and irq number
are all handled in imx_hdmi_bind


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ