1 cat <<EOF 1 cat <<EOF 2 return raw_${atomic}_add_unless(v, 1, !! 2 /** >> 3 * ${atomic}_inc_not_zero - increment unless the number is zero >> 4 * @v: pointer of type ${atomic}_t >> 5 * >> 6 * Atomically increments @v by 1, if @v is non-zero. >> 7 * Returns true if the increment was done. >> 8 */ >> 9 static inline bool >> 10 ${atomic}_inc_not_zero(${atomic}_t *v) >> 11 { >> 12 return ${atomic}_add_unless(v, 1, 0); >> 13 } 3 EOF 14 EOF
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.