Re: FW: Cannot add integer value with N upper zero bits to ptr_to_packet

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

 



On 06/21/2017 05:55 PM, Y Song wrote:
This is a verifier error. Do you have a test case? I can take a
further look at this.

On Wed, Jun 21, 2017 at 6:35 AM, Panneman, J.J. (Jeffrey)
<jeffrey.panneman@xxxxxx> wrote:
Hi All,

I currently have another issue which seems rather weird. I have a variable with type uint8_t, this is passed as reference to a function in which it gets a value. When I do this a single time, the variable gets a value and I can print it with the trace print call. Now when I do this a second time, I get the 'cannot add integer value with 0 upper zero bits to ptr_to_packet' message, I have also tried to create another variable and assign it to this but this did not resolve anything.

is there some restrictions on changing values ? The message doesn't really give me enough to work out the exact issue.

Happy to provide verifier output and code for those who might have an idea.

The error message usually happens when you have register that contains
{skb,xdp}->data or some pointer derived from this, and you add another
register to it that has a unknown value, where verifier has no knowledge
of what the upper bound could be of that register so that it cannot
guarantee that this won't turn into a overflow (it expects 48 or more
zero upper bits). The passing by reference might not necessarily be the
cause for triggering this, but rather the addition that you perform
somewhere in your code. Test case would help indeed to see what you're
doing.



[Index of Archives]     [Linux Networking Development]     [Fedora Linux Users]     [Linux SCTP]     [DCCP]     [Gimp]     [Yosemite Campsites]

  Powered by Linux