Thank you for your contribution! Sashiko AI review found 1 potential issue to consider: - [Low] overflow: inaccurate kernel-doc Return comment for struct_offsetofend() --
commit a83afd15b73f01058421922341af6cf7cf31d535 Author: Bence Csokas <[email protected]> stddef: Add offsetofend() variant of struct_offset() This commit adds the struct_offsetofend() macro to include/linux/overflow.h to calculate offsetofend() on the type of a struct pointer. > diff --git a/include/linux/overflow.h b/include/linux/overflow.h > index d0f04436343e5..060dad4b6f3e0 100644 > --- a/include/linux/overflow.h > +++ b/include/linux/overflow.h > @@ -464,6 +464,18 @@ static __always_inline size_t __must_check > size_sub(size_t minuend, size_t subtr > */ > #define struct_offset(p, member) (offsetof(typeof(*(p)), member)) > > +/** > + * struct_offsetofend() - Calculate the end of a member within a struct > + * @p: Pointer to the struct > + * @member: Name of the member to get the end offset of > + * > + * Calculates the offset of the end of a particular @member of the structure > + * pointed to by @p. > + * > + * Return: number of bytes to the location of @member. > + */ > +#define struct_offsetofend(p, member) (offsetofend(typeof(*(p)), member)) [Severity: Low] This isn't a bug, but the Return description was copied from struct_offset() and says "the location of @member" rather than the end of @member. Also, the commit message body refers to adding an "offsetof() variant" instead of an offsetofend() variant, and the subject uses the "stddef:" prefix for a change in include/linux/overflow.h. -- Sashiko AI review ยท https://sashiko.dev/#/patchset/[email protected]?part=1
