[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v3 1/2] bitops: drop volatile qualifier
From: |
Blue Swirl |
Subject: |
Re: [Qemu-devel] [PATCH v3 1/2] bitops: drop volatile qualifier |
Date: |
Mon, 23 Jul 2012 16:38:18 +0000 |
On Mon, Jul 16, 2012 at 2:40 PM, Eric Blake <address@hidden> wrote:
> On 07/14/2012 06:34 AM, Blue Swirl wrote:
>> Qualifier 'volatile' is not useful for applications, it's too strict
>> for single threaded code but does not give the real atomicity guarantees
>> needed for multithreaded code.
>>
>> Drop them and now useless casts.
>>
>
>> -static inline void set_bit(int nr, volatile unsigned long *addr)
>> +static inline void set_bit(int nr, unsigned long *addr)
>> {
>> unsigned long mask = BIT_MASK(nr);
>> - unsigned long *p = ((unsigned long *)addr) + BIT_WORD(nr);
>> + unsigned long *p = addr + BIT_WORD(nr);
>
> The diff looks weird, because you are converting TAB to space on your
> affected lines but not cleaning up the neighboring lines. Is it worth a
> preliminary patch to whitespace-sanitize things?
That is close to reformatting, this is the usual way these days.
>
> --
> Eric Blake address@hidden +1-919-301-3266
> Libvirt virtualization library http://libvirt.org
>
- [Qemu-devel] [PATCH v3 0/2] bitops patches, Blue Swirl, 2012/07/14
- [Qemu-devel] [PATCH v3 1/2] bitops: drop volatile qualifier, Blue Swirl, 2012/07/14
- [Qemu-devel] [PATCH v3 2/2] bitops: fix types, Blue Swirl, 2012/07/14
- Re: [Qemu-devel] [PATCH v3 2/2] bitops: fix types, Avi Kivity, 2012/07/16
- Re: [Qemu-devel] [PATCH v3 2/2] bitops: fix types, Peter Maydell, 2012/07/16
- Re: [Qemu-devel] [PATCH v3 2/2] bitops: fix types, Markus Armbruster, 2012/07/17
- Re: [Qemu-devel] [PATCH v3 2/2] bitops: fix types, Blue Swirl, 2012/07/23
- Re: [Qemu-devel] [PATCH v3 2/2] bitops: fix types, Peter Maydell, 2012/07/23
- Re: [Qemu-devel] [PATCH v3 2/2] bitops: fix types, Markus Armbruster, 2012/07/24
- Re: [Qemu-devel] [PATCH v3 2/2] bitops: fix types, Blue Swirl, 2012/07/24