Hi, On 12/4/2023 3:04 AM, Alexei Starovoitov wrote: > On Thu, Nov 30, 2023 at 10:01:20PM +0800, Hou Tao wrote: >> >> - prog_load_attr.license = (long) license; >> - prog_load_attr.insns = (long) insns; >> + prog_load_attr.license = (unsigned long)license; >> + prog_load_attr.insns = (unsigned long)insns; > Maybes keep it as (long) ? > There are plenty of case where we cast a pointer to (long) because > it's less verbose. Signedness shouldn't really matter. It matters for 32-bits host. Because insns and license are the pointers in kernel space, so the MSB of these pointer must be 1 under 32-bits host. Assuming the value of license is 0xc000-0000, if using (u64)(long) to cast the value of license, the final value will be 0xffff-ffff-c000-0000, instead of 0x0000-0000-c000-0000. > Or use ptr_to_u64(). Will add and use ptr_to_u64() in v5. Thanks for all these suggestions. > > pw-bot: cr