Re: [PATCH] cpumask 5/10 rewrite cpumask.h - single bitmap based implementation

From: Keith Owens
Date: Fri Jun 04 2004 - 03:48:06 EST


On Fri, 4 Jun 2004 01:19:06 -0700,
William Lee Irwin III <wli@xxxxxxxxxxxxxx> wrote:
>On Thu, Jun 03, 2004 at 10:10:10AM -0700, Paul Jackson wrote:
>> @@ -1206,9 +1207,10 @@
>> {
>> struct ino_bucket *bp = ivector_table + (long)data;
>> struct irqaction *ap = bp->irq_info;
>> - cpumask_t mask = get_smpaff_in_irqaction(ap);
>> + cpumask_t mask;
>> int len;
>>
>> + cpus_addr(mask)[0] = get_smpaff_in_irqaction(ap);
>> if (cpus_empty(mask))
>> mask = cpu_online_map;
>
>This is an improvement?

The existing code assumes that cpumask_t fits in a long; struct
irqaction->mask is defined as a long. Paul marked such suspect code
with cpus_addr(), it needs to be reviewed and corrected.

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