Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1621874
| From | Thomas Gleixner <tglx@linutronix.de> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] kernel/irq: Limit validation of cpumask_var_t to CONFIG_CPUMASK_OFFSTACK=y |
| Date | 2017-04-12 09:30 +0200 |
| Message-ID | <tvkT0-1CE-13@gated-at.bofh.it> (permalink) |
| References | <tvdRw-5mf-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Tue, 11 Apr 2017, Matthias Kaehlcke wrote: > With CONFIG_CPUMASK_OFFSTACK=y cpumask_var_t is a struct cpumask > pointer, otherwise a struct cpumask array with a single element. > > irq_thread_check_affinity() validates the cpumask_var_t field in the > interrupt descriptor by checking if it is not NULL. This works for > both CONFIG_CPUMASK_OFFSTACK=y/n, however clang raises the following > warning with CONFIG_CPUMASK_OFFSTACK=n: > > kernel/irq/manage.c:839:28: error: address of array > 'desc->irq_common_data.affinity' will always evaluate to 'true' > [-Werror,-Wpointer-bool-conversion] > > To get rid of the warning only validate the cpumask_var_t field when > CONFIG_CPUMASK_OFFSTACK=y. This ifdeffery is horrible. Can you please create a helper inline cpumask_available() or something like that which hides this in a header file. The irq code is probably not the only place which does this. Thanks, tglx
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH] kernel/irq: Limit validation of cpumask_var_t to CONFIG_CPUMASK_OFFSTACK=y Matthias Kaehlcke <mka@chromium.org> - 2017-04-12 02:00 +0200
Re: [PATCH] kernel/irq: Limit validation of cpumask_var_t to CONFIG_CPUMASK_OFFSTACK=y Thomas Gleixner <tglx@linutronix.de> - 2017-04-12 09:30 +0200
Re: [PATCH] kernel/irq: Limit validation of cpumask_var_t to CONFIG_CPUMASK_OFFSTACK=y Matthias Kaehlcke <mka@chromium.org> - 2017-04-12 18:50 +0200
csiph-web