search for: __va_args__

Displaying 20 results from an estimated 339 matches for "__va_args__".

2019 May 23
4
[RFC][PATCH] kernel.h: Add generic roundup_64() macro
On Thu, 23 May 2019 08:10:44 -0700 Linus Torvalds <torvalds at linux-foundation.org> wrote: > On Thu, May 23, 2019 at 7:00 AM Steven Rostedt <rostedt at goodmis.org> wrote: > > > > +# define roundup_64(x, y) ( \ > > +{ \ > > + typeof(y) __y = y;
2019 May 23
0
[RFC][PATCH] kernel.h: Add generic roundup_64() macro
...and is always efficient. On a slight tangent.. Maybe we should have something like this: #define size_fn(x, prefix, ...) ({ \ typeof(x) __ret; \ switch (sizeof(x)) { \ case 1: __ret = prefix##8(__VA_ARGS__); break; \ case 2: __ret = prefix##16(__VA_ARGS__); break; \ case 4: __ret = prefix##32(__VA_ARGS__); break; \ case 8: __ret = prefix##64(__VA_ARGS__); break; \ default: __ret = prefix##bad(__VA_ARGS__); \ } __ret; }) #define type_fn(x, prefix, ...) ({...
2019 May 23
1
[RFC][PATCH] kernel.h: Add generic roundup_64() macro
...; On a slight tangent.. Maybe we should have something like this: > > #define size_fn(x, prefix, ...) ({ \ > typeof(x) __ret; \ > switch (sizeof(x)) { \ > case 1: __ret = prefix##8(__VA_ARGS__); break; \ > case 2: __ret = prefix##16(__VA_ARGS__); break; \ > case 4: __ret = prefix##32(__VA_ARGS__); break; \ > case 8: __ret = prefix##64(__VA_ARGS__); break; \ > default: __ret = prefix##bad(__VA_ARGS__); \ > } __ret; }) > >...
2017 Feb 28
0
[PATCH 3/3] gpu: drm: drivers: Convert printk(KERN_<LEVEL> to pr_<level>
...m/dss/dss.h index 56493b290731..78f6fc75948b 100644 --- a/drivers/gpu/drm/omapdrm/dss/dss.h +++ b/drivers/gpu/drm/omapdrm/dss/dss.h @@ -42,29 +42,26 @@ #ifdef DSS_SUBSYS_NAME #define DSSERR(format, ...) \ - printk(KERN_ERR "omapdss " DSS_SUBSYS_NAME " error: " format, \ - ## __VA_ARGS__) + pr_err("omapdss " DSS_SUBSYS_NAME " error: " format, ##__VA_ARGS__) #else #define DSSERR(format, ...) \ - printk(KERN_ERR "omapdss error: " format, ## __VA_ARGS__) + pr_err("omapdss error: " format, ##__VA_ARGS__) #endif #ifdef DSS_SUBSYS_NAME #defi...
2018 Nov 02
0
[PATCH v3 2/4] common/utils: Move libxml2 writer macros to a common header file.
...\ + } while (0) + +#define attribute_format(key,fs,...) \ + do { \ + if (xmlTextWriterWriteFormatAttribute (xo, BAD_CAST (key), \ + fs, ##__VA_ARGS__) == -1) { \ + xml_error ("xmlTextWriterWriteFormatAttribute"); \ + } \ + } while (0) + +/** + * C<attribute_ns (prefix, key, namespace_uri, value)> defines a + * namespaced attribute. + */ +...
2008 Jun 24
4
Problem Compiling 1.1.1 on AIX
...s separated by commas. make: 1254-004 The error code from the last command is 1. Looking at macros.h, the section it is erroring on is: #ifdef CONTEXT_TYPE_SAFETY # define CONTEXT_CALLBACK(name, callback_type, callback, context, ...) \ ({(void)(1 ? 0 : callback(context)); \ name(__VA_ARGS__, (callback_type *)callback, context); }) #else # define CONTEXT_CALLBACK(name, callback_type, callback, context, ...) \ name(__VA_ARGS__, (callback_type *)callback, context) #endif The second define is the line the error occurs on. Has anyone seen this before. I'm assuming xlc can...
2018 Aug 30
3
[PATCH 0/2] drm/nouveau: Use more standard logging styles
Reduces object size ~4kb Joe Perches (2): drm/nouveau: Add new logging function nv_cli_printk drm/nouveau: Convert NV_PRINTK macros and uses to new nv_cli_<level> macros drivers/gpu/drm/nouveau/nouveau_abi16.c | 2 +- drivers/gpu/drm/nouveau/nouveau_chan.c | 12 +++---- drivers/gpu/drm/nouveau/nouveau_drm.c | 21 +++++++++++ drivers/gpu/drm/nouveau/nouveau_drv.h | 44
2017 Feb 28
8
[PATCH 2/2] gpu: drm: Convert printk(KERN_<LEVEL> to pr_<level>
...948b 100644 > --- a/drivers/gpu/drm/omapdrm/dss/dss.h > +++ b/drivers/gpu/drm/omapdrm/dss/dss.h > @@ -42,29 +42,26 @@ > > #ifdef DSS_SUBSYS_NAME > #define DSSERR(format, ...) \ > - printk(KERN_ERR "omapdss " DSS_SUBSYS_NAME " error: " format, \ > - ## __VA_ARGS__) > + pr_err("omapdss " DSS_SUBSYS_NAME " error: " format, ##__VA_ARGS__) > #else > #define DSSERR(format, ...) \ > - printk(KERN_ERR "omapdss error: " format, ## __VA_ARGS__) > + pr_err("omapdss error: " format, ##__VA_ARGS__) > #endif &g...
2017 Oct 04
1
[PATCH 02/13] x86/paravirt: Fix output constraint macro names
...ot;, "r11" @@ -552,12 +552,12 @@ int paravirt_disable_iospace(void); }) #define __PVOP_CALL(rettype, op, pre, post, ...) \ - ____PVOP_CALL(rettype, op, CLBR_ANY, PVOP_CALL_CLOBBERS, \ + ____PVOP_CALL(rettype, op, CLBR_ANY, PVOP_CALL_OUTPUTS, \ EXTRA_CLOBBERS, pre, post, ##__VA_ARGS__) #define __PVOP_CALLEESAVE(rettype, op, pre, post, ...) \ ____PVOP_CALL(rettype, op.func, CLBR_RET_REG, \ - PVOP_CALLEE_CLOBBERS, , \ + PVOP_CALLEE_OUTPUTS, , \ pre, post, ##__VA_ARGS__) @@ -576,13 +576,13 @@ int paravirt_disable_iospace(void); }) #def...
2023 Feb 15
1
[libnbd PATCH v3 02/29] generator/C.ml: use space consistently in func. and func.-like macro calls
...nged, 10 insertions(+), 10 deletions(-) > > pr "#ifndef LIBNBD_ATTRIBUTE_NONNULL\n"; > - pr "#if defined(__GNUC__) && LIBNBD_GCC_VERSION >= 120000 /* gcc >= 12.0 */\n"; > - pr "#define LIBNBD_ATTRIBUTE_NONNULL(...) __attribute__((__nonnull__(__VA_ARGS__)))\n"; > + pr "#if defined (__GNUC__) && LIBNBD_GCC_VERSION >= 120000 /* gcc >= 12.0 */\n"; > + pr "#define LIBNBD_ATTRIBUTE_NONNULL(...) __attribute__ ((__nonnull__ (__VA_ARGS__)))\n"; Not only are these lines long in our source, they are long in the...
2017 Oct 04
1
[PATCH 11/13] x86/paravirt: Add paravirt alternatives infrastructure
...;.short " clobber "\n" \ + ".popsection\n" \ + #define PARAVIRT_PATCH(x) \ (offsetof(struct paravirt_patch_template, x) / sizeof(void *)) @@ -559,6 +586,33 @@ int paravirt_disable_iospace(void); PVOP_CALLEE_OUTPUTS, , \ pre, post, ##__VA_ARGS__) +#define ____PVOP_ALT_CALL(rettype, native, op, clbr, call_clbr, \ + extra_clbr, ...) \ +({ \ + rettype __ret; \ + PVOP_CALL_ARGS; \ + PVOP_TEST_NULL(op); \ + asm volatile(PV_ALT_SITE(native, PV_CALL_STR) \ + : call_clbr, ASM_CALL_CONSTRAINT \ +...
2023 Feb 15
2
[libnbd PATCH v3 02/29] generator/C.ml: use space consistently in func. and func.-like macro calls
..._)\n"; pr "#endif\n"; pr "\n"; pr "#ifndef LIBNBD_ATTRIBUTE_NONNULL\n"; - pr "#if defined(__GNUC__) && LIBNBD_GCC_VERSION >= 120000 /* gcc >= 12.0 */\n"; - pr "#define LIBNBD_ATTRIBUTE_NONNULL(...) __attribute__((__nonnull__(__VA_ARGS__)))\n"; + pr "#if defined (__GNUC__) && LIBNBD_GCC_VERSION >= 120000 /* gcc >= 12.0 */\n"; + pr "#define LIBNBD_ATTRIBUTE_NONNULL(...) __attribute__ ((__nonnull__ (__VA_ARGS__)))\n"; pr "#else\n"; pr "#define LIBNBD_ATTRIBUTE_NONNULL(...)...
2007 Apr 18
2
libswfdec/jpeg
libswfdec/jpeg/jpeg_rgb_decoder.c | 1 - 1 files changed, 1 deletion(-) New commits: diff-tree 15ed4a69b4ffc265fe103ba79a0b60af7e42a9fa (from 2073f39bc0b0aa90f1f67def9bb3f0c6b68018ae) Author: Benjamin Otte <otte@gnome.org> Date: Wed Apr 18 10:47:06 2007 +0200 remove leftover debugging statement diff --git a/libswfdec/jpeg/jpeg_rgb_decoder.c b/libswfdec/jpeg/jpeg_rgb_decoder.c
2017 Oct 04
0
[PATCH 07/13] x86/paravirt: Simplify ____PVOP_CALL()
...ion will never hold */ \ - if (sizeof(rettype) > sizeof(unsigned long)) { \ - asm volatile(pre \ - paravirt_alt(PARAVIRT_CALL) \ - post \ - : call_clbr, ASM_CALL_CONSTRAINT \ - : paravirt_type(op), \ - paravirt_clobber(clbr), \ - ##__VA_ARGS__ \ - : "memory", "cc" extra_clbr); \ - __ret = (rettype)((((u64)__edx) << 32) | __eax); \ - } else { \ - asm volatile(pre \ - paravirt_alt(PARAVIRT_CALL) \ - post \ - : call_clbr, ASM_CALL_CONSTRAINT \ - : paravirt_t...
2014 Aug 12
4
[LLVMdev] Explicit template instantiations in libc++
...f common templates will be emitted by the compiler and coalesced by the linker. Notably, in include/__config, we have: #ifndef _LIBCPP_EXTERN_TEMPLATE #define _LIBCPP_EXTERN_TEMPLATE(...) #endif whereas before r189601 this was: #define _LIBCPP_EXTERN_TEMPLATE(...) extern template __VA_ARGS__; This was apparently done to fix http://llvm.org/bugs/show_bug.cgi?id=17027, but disabling explicit instantiations seems like a pretty big hammer considering the drawbacks. I'd like to restore these instantiations. Any thoughts on how to handle things like pr17027 in a less heavy handed way?
2020 Feb 07
2
[PATCH 2/6] drm: Add drm_simple_encoder_{init,create}()
...+int drm_simple_encoder_init(struct drm_device *dev, > + struct drm_encoder *encoder, > + int encoder_type, const char *name, ...) How about using #define drm_simple_encoder_init(dev, type, name, ...) \ drm_encoder_init(dev, drm_simple_encoder_funcs_cleanup, type, name, __VA_ARGS__) instead ? cheers, Gerd
2020 Feb 07
2
[PATCH 2/6] drm: Add drm_simple_encoder_{init,create}()
...+int drm_simple_encoder_init(struct drm_device *dev, > + struct drm_encoder *encoder, > + int encoder_type, const char *name, ...) How about using #define drm_simple_encoder_init(dev, type, name, ...) \ drm_encoder_init(dev, drm_simple_encoder_funcs_cleanup, type, name, __VA_ARGS__) instead ? cheers, Gerd
2020 Jan 09
0
[PATCH v2 4/4] daemon: drop usage of C augeas library
...\ - do { \ - const int code = aug_error (aug); \ - if (code == AUG_ENOMEM) \ - reply_with_error (fs ": augeas out of memory", ##__VA_ARGS__); \ - else { \ - const char *aug_err_message = aug_error_message (aug); \ - const char *aug_err_minor = aug_error_minor_message (aug); \ - const char *aug_err_details = aug_error_details (aug);...
2020 Mar 09
0
[PATCH v3 3/3] daemon: drop usage of C augeas library
...\ - do { \ - const int code = aug_error (aug); \ - if (code == AUG_ENOMEM) \ - reply_with_error (fs ": augeas out of memory", ##__VA_ARGS__); \ - else { \ - const char *aug_err_message = aug_error_message (aug); \ - const char *aug_err_minor = aug_error_minor_message (aug); \ - const char *aug_err_details = aug_error_details (aug);...
2018 Oct 04
0
[PATCH v2 2/4] common/utils: Move libxml2 writer macros to a common header file.
...me> >>> + */ +#define attribute(key,fs,...) \ + do { \ + if (xmlTextWriterWriteFormatAttribute (xo, BAD_CAST (key), \ + fs, ##__VA_ARGS__) == -1) { \ + xml_error ("xmlTextWriterWriteFormatAttribute"); \ + } \ + } while (0) + +/** + * C<attribute_ns (prefix, key, namespace_uri, value)> defines a + * namespaced attribute. + */ +...