Re: [PATCH 09/33] configfs: Introduce config_item_get_unless_zero()

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

 



> +struct config_item *config_item_get_unless_zero(struct config_item *item)
> +{
> +	return item && kref_get_unless_zero(&item->ci_kref) ? item : NULL;
> +}
> +EXPORT_SYMBOL(config_item_get_unless_zero);

Style nipick, I'd prefer something like:

	if (item && !kref_get_unless_zero(&item->ci_kref))
		item = NULL;
	return item;

Otherwise this looks fine to me:

Reviewed-by: Christoph Hellwig <hch@xxxxxx>

or should I pick it up through the configfs tree?
--
To unsubscribe from this list: send the line "unsubscribe target-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux SCSI]     [Kernel Newbies]     [Linux SCSI Target Infrastructure]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Device Mapper]

  Powered by Linux