[dpdk-dev] [PATCH v3 1/2] ring: synchronize the load and store of the tail

Stephen Hemminger stephen at networkplumber.org
Wed Oct 31 23:07:50 CET 2018


On Wed, 31 Oct 2018 18:26:26 +0800
Gavin Hu <gavin.hu at arm.com> wrote:

> -		/*
> -		 *  The subtraction is done between two unsigned 32bits value
> +		/* load-acquire synchronize with store-release of ht->tail
> +		 * in update_tail.
> +		 */
> +		const uint32_t cons_tail

Please don't mix declarations and code. Although it is sometimes used in DPDK,
in general the style is to have declarations at the start of the block scope.


More information about the dev mailing list