On Thu, Jul 24, 2025 at 08:40:12AM +1000, Stephen Rothwell wrote:
On Wed, 23 Jul 2025 18:29:34 +0300 Andy Shevchenko andriy.shevchenko@linux.intel.com wrote:
On Mon, Jul 21, 2025 at 02:13:52PM -0700, Andrew Morton wrote:
From: Stephen Rothwell sfr@canb.auug.org.au Subject: sprintf.h requires stdarg.h Date: Mon, 21 Jul 2025 16:15:57 +1000
In file included from drivers/crypto/intel/qat/qat_common/adf_pm_dbgfs_utils.c:4: include/linux/sprintf.h:11:54: error: unknown type name 'va_list' 11 | __printf(2, 0) int vsprintf(char *buf, const char *, va_list); | ^~~~~~~ include/linux/sprintf.h:1:1: note: 'va_list' is defined in header '<stdarg.h>'; this is probably fixable by adding '#include <stdarg.h>'
...
#include <linux/compiler_attributes.h> #include <linux/types.h> +#include <linux/stdarg.h>
Can we prevent the ordering?
I am not sure what you mean by this. Do you want alphabetical, reverse christmas tree, or something else? Or are you concerned with something completely different?
Alphabetical
#include <linux/compiler_attributes.h> #include <linux/stdarg.h> #include <linux/types.h>