Re: [PATCH 14/16] bcache: Make csum_set() implementation easier to read

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Mar 15, 2018 at 08:08:12AM -0700, Bart Van Assche wrote:
> +#define csum_set(i) ({						\
> +	const void *p = (void *)(i) + sizeof(uint64_t);		\
> +	const void *q = bset_bkey_last(i);			\
> +								\
> +	bch_crc64(p, q - p);					\
> +})

Having this as a macro is really ugly.  Any chane to turn this into a
proper function?



[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux