Re: [PATCH] net_sched: force endianness annotation

From: Christoph Hellwig
Date: Mon Apr 29 2019 - 08:09:44 EST


On Sun, Apr 28, 2019 at 07:54:59AM +0200, Nicholas Mc Guire wrote:
> While the endiannes is being handled correctly sparse was unhappy with
> the missing annotation as be16_to_cpu()/be32_to_cpu() expects a __be16
> respectively __be32. To mitigate this annotation issue forced annotation
> is introduced. Note that this patch has no impact on the generated binary.

Every __force needs a comment explaining why it actually Ñs fine in
this particular case. Even more bonus points for finding a solution
that does not require the __force.