dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: arvind <arvind.yadav.cs@gmail.com>
To: "Christian König" <deathsimple@vodafone.de>,
	airlied@linux.ie, amd-gfx@lists.freedesktop.org,
	alexander.deucher@amd.com, dri-devel@lists.freedesktop.org
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/5] drm: radeon: constify pci_device_id.
Date: Sun, 16 Jul 2017 11:40:28 +0530	[thread overview]
Message-ID: <596B0354.6030703@gmail.com> (raw)
In-Reply-To: <94559aac-60b7-d2f9-7594-89e939980dd5@vodafone.de>


[-- Attachment #1.1: Type: text/plain, Size: 1788 bytes --]

Hi Christian,

On Saturday 15 July 2017 07:17 PM, Christian König wrote:
> Am 15.07.2017 um 09:12 schrieb Arvind Yadav:
>> pci_device_id are not supposed to change at runtime. All functions
>> working with pci_device_id provided by <linux/pci.h> work with
>> const pci_device_id. So mark the non-const structs as const.
>>
>> File size before:
>>     text       data        bss        dec        hex    filename
>>     6560      23212         72      29844       7494 
>> gpu/drm/radeon/radeon_drv.o
>>
>> File size After adding 'const':
>>     text       data        bss        dec        hex    filename
>>    28960        812         72      29844       7494 
>> gpu/drm/radeon/radeon_drv.o
>>
>> Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
>
> Impressive result for such a simple change.
>
> Patch is Reviewed-by: Christian König <christian.koenig@amd.com>
>
> Are the PCI IDs already const in amdgpu or do we need a similar patch 
> there as well? I only see patch 1 of 5 in my inbox.
I have send all gpu patch to David Airlie. Please check with him.
>
> Christian.
>
>> ---
>>   drivers/gpu/drm/radeon/radeon_drv.c | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/radeon/radeon_drv.c 
>> b/drivers/gpu/drm/radeon/radeon_drv.c
>> index e25cb51..b079937 100644
>> --- a/drivers/gpu/drm/radeon/radeon_drv.c
>> +++ b/drivers/gpu/drm/radeon/radeon_drv.c
>> @@ -298,7 +298,7 @@ module_param_named(uvd, radeon_uvd, int, 0444);
>>   MODULE_PARM_DESC(vce, "vce enable/disable vce support (1 = enable, 
>> 0 = disable)");
>>   module_param_named(vce, radeon_vce, int, 0444);
>>   -static struct pci_device_id pciidlist[] = {
>> +static const struct pci_device_id pciidlist[] = {
>>       radeon_PCI_IDS
>>   };
>
>
>
Regards,
~arvind

[-- Attachment #1.2: Type: text/html, Size: 4598 bytes --]

[-- Attachment #2: Type: text/plain, Size: 160 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

      reply	other threads:[~2017-07-16  6:10 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-15  7:12 [PATCH 0/5] constify drm pci_device_id Arvind Yadav
2017-07-15  7:12 ` [PATCH 1/5] drm: radeon: constify pci_device_id Arvind Yadav
2017-07-15 13:47   ` Christian König
2017-07-16  6:10     ` arvind [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=596B0354.6030703@gmail.com \
    --to=arvind.yadav.cs@gmail.com \
    --cc=airlied@linux.ie \
    --cc=alexander.deucher@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=deathsimple@vodafone.de \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox