From: Jani Nikula <jani.nikula@linux.intel.com>
To: "Upadhyay, Tejas" <tejas.upadhyay@intel.com>,
"Gote, Nitin R" <nitin.r.gote@intel.com>,
"intel-xe@lists.freedesktop.org" <intel-xe@lists.freedesktop.org>
Cc: "Piorkowski, Piotr" <piotr.piorkowski@intel.com>,
"Gote, Nitin R" <nitin.r.gote@intel.com>
Subject: RE: [PATCH] drm/xe: Use IS_ENABLED() for config checks instead of defined()
Date: Mon, 01 Dec 2025 15:55:22 +0200 [thread overview]
Message-ID: <170172a4dd8a4262611287ca2e189258845a5d23@intel.com> (raw)
In-Reply-To: <SJ1PR11MB620465985EABAEF33646A24581DBA@SJ1PR11MB6204.namprd11.prod.outlook.com>
On Mon, 01 Dec 2025, "Upadhyay, Tejas" <tejas.upadhyay@intel.com> wrote:
>> -----Original Message-----
>> From: Intel-xe <intel-xe-bounces@lists.freedesktop.org> On Behalf Of Nitin
>> Gote
>> Sent: 27 November 2025 22:37
>> To: intel-xe@lists.freedesktop.org
>> Cc: Piorkowski, Piotr <piotr.piorkowski@intel.com>; Gote, Nitin R
>> <nitin.r.gote@intel.com>
>> Subject: [PATCH] drm/xe: Use IS_ENABLED() for config checks instead of
>> defined()
>>
>> Prefer IS_ENABLED() instead of defined() for checking whether a kconfig
>> option is enabled.
>
> Add little info why
That's just what you're supposed to do. ;)
BR,
Jani.
>
> Tejas
>>
>> Signed-off-by: Nitin Gote <nitin.r.gote@intel.com>
>> ---
>> drivers/gpu/drm/xe/xe_vram.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/xe/xe_vram.c b/drivers/gpu/drm/xe/xe_vram.c
>> index 0a645e76e5fa..8fac1cc08dc9 100644
>> --- a/drivers/gpu/drm/xe/xe_vram.c
>> +++ b/drivers/gpu/drm/xe/xe_vram.c
>> @@ -325,7 +325,7 @@ struct xe_vram_region *xe_vram_region_alloc(struct
>> xe_device *xe, u8 id, u32 pla
>> vram->xe = xe;
>> vram->id = id;
>> vram->placement = placement;
>> -#if defined(CONFIG_DRM_XE_PAGEMAP)
>> +#if IS_ENABLED(CONFIG_DRM_XE_PAGEMAP)
>> vram->migrate = xe->tiles[id].migrate; #endif
>> return vram;
>> --
>> 2.50.1
>
--
Jani Nikula, Intel
next prev parent reply other threads:[~2025-12-01 13:55 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-27 17:06 [PATCH] drm/xe: Use IS_ENABLED() for config checks instead of defined() Nitin Gote
2025-11-27 17:36 ` ✓ CI.KUnit: success for " Patchwork
2025-11-27 18:38 ` ✓ Xe.CI.BAT: " Patchwork
2025-11-27 20:17 ` ✗ Xe.CI.Full: failure " Patchwork
2025-12-01 11:50 ` [PATCH] " Upadhyay, Tejas
2025-12-01 13:55 ` Jani Nikula [this message]
-- strict thread matches above, loose matches on Subject: below --
2025-12-02 7:02 Nitin Gote
2025-12-02 23:45 ` Lin, Shuicheng
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=170172a4dd8a4262611287ca2e189258845a5d23@intel.com \
--to=jani.nikula@linux.intel.com \
--cc=intel-xe@lists.freedesktop.org \
--cc=nitin.r.gote@intel.com \
--cc=piotr.piorkowski@intel.com \
--cc=tejas.upadhyay@intel.com \
/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