From: Čestmír Kalina <ckalina@xxxxxxxxxx> kabi: introduce RH_KABI_ADD_MODIFIER Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2024595 Upstream Status: RHEL only commit e8c19640a09931c05012dd9a45c28d12dc7b2a02 Author: Jiri Benc <jbenc@xxxxxxxxxx> Date: Wed, 1 Apr 2020 13:04:03 -0400 This is a generalized version of RH_KABI_CONST. This allows RH_KABI_REPLACE_UNSAFE to be removed in a later patch. RH-Signed-off-by: Jiri Benc <jbenc@xxxxxxxxxx> Signed-off-by: Čestmír Kalina <ckalina@xxxxxxxxxx> Signed-off-by: Prarit Bhargava <prarit@xxxxxxxxxx> diff --git a/include/linux/rh_kabi.h b/include/linux/rh_kabi.h index blahblah..blahblah 100644 --- a/include/linux/rh_kabi.h +++ b/include/linux/rh_kabi.h @@ -43,6 +43,13 @@ * Adds a new const modifier to a function parameter preserving the old * checksum. * + * RH_KABI_ADD_MODIFIER + * Adds a new modifier to a function parameter or a typedef, preserving + * the old checksum. Useful e.g. for adding rcu annotations or changing + * int to unsigned. Beware that this may change the semantics; if you're + * sure this is safe, always explain why binary compatibility with 3rd + * party modules is retained. + * * RH_KABI_DEPRECATE * Mark the element as deprecated and make it unusable by modules while * preserving kABI checksums. @@ -173,6 +180,7 @@ #ifdef __GENKSYMS__ # define RH_KABI_CONST +# define RH_KABI_ADD_MODIFIER(_new) # define RH_KABI_EXTEND(_new) # define RH_KABI_FILL_HOLE(_new) # define RH_KABI_FORCE_CHANGE(ver) __attribute__((rh_kabi_change ## ver)) @@ -195,6 +203,7 @@ # define RH_KABI_ALIGN_WARNING ". Disable CONFIG_RH_KABI_SIZE_ALIGN_CHECKS if debugging." # define RH_KABI_CONST const +# define RH_KABI_ADD_MODIFIER(_new) _new # define RH_KABI_EXTEND(_new) _new; # define RH_KABI_FILL_HOLE(_new) _new; # define RH_KABI_FORCE_CHANGE(ver) -- https://gitlab.com/cki-project/kernel-ark/-/merge_requests/1530 _______________________________________________ kernel mailing list -- kernel@xxxxxxxxxxxxxxxxxxxxxxx To unsubscribe send an email to kernel-leave@xxxxxxxxxxxxxxxxxxxxxxx Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/kernel@xxxxxxxxxxxxxxxxxxxxxxx Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure