linux/fs/hfs
Robert P. J. Day 82ddcb0405 [PATCH] extend the set of "__attribute__" shortcut macros
Extend the set of "__attribute__" shortcut macros, and remove identical
(and now superfluous) definitions from a couple of source files.

based on a page at robert love's blog:

	http://rlove.org/log/2005102601

extend the set of shortcut macros defined in compiler-gcc.h with the
following:

#define __packed                       __attribute__((packed))
#define __weak                         __attribute__((weak))
#define __naked                        __attribute__((naked))
#define __noreturn                     __attribute__((noreturn))
#define __pure                         __attribute__((pure))
#define __aligned(x)                   __attribute__((aligned(x)))
#define __printf(a,b)                  __attribute__((format(printf,a,b)))

Once these are in place, it's up to subsystem maintainers to decide if they
want to take advantage of them.  there is already a strong precedent for
using shortcuts like this in the source tree.

The ones that might give people pause are "__aligned" and "__printf", but
shortcuts for both of those are already in use, and in some ways very
confusingly.  note the two very different definitions for a macro named
"ALIGNED":

  drivers/net/sgiseeq.c:#define ALIGNED(x) ((((unsigned long)(x)) + 0xf) & ~(0xf))
  drivers/scsi/ultrastor.c:#define ALIGNED(x) __attribute__((aligned(x)))

also:

  include/acpi/platform/acgcc.h:
    #define ACPI_PRINTF_LIKE(c) __attribute__ ((__format__ (__printf__, c, c+1)))

Given the precedent, then, it seems logical to at least standardize on a
consistent set of these macros.

Signed-off-by: Robert P. J. Day <rpjday@mindspring.com>
Acked-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-02-11 10:51:35 -08:00
..
attr.c
bfind.c [PATCH] hfs: cleanup HFS prints 2006-01-18 19:20:23 -08:00
bitmap.c
bnode.c [PATCH] fs: Conversions from kmalloc+memset to k(z|c)alloc 2006-09-27 08:26:10 -07:00
brec.c [PATCH] hfs: cleanup HFS prints 2006-01-18 19:20:23 -08:00
btree.c [PATCH] fs: Conversions from kmalloc+memset to k(z|c)alloc 2006-09-27 08:26:10 -07:00
btree.h
catalog.c [PATCH] hfs: cleanup HFS prints 2006-01-18 19:20:23 -08:00
dir.c [PATCH] struct path: convert hfs 2006-12-08 08:28:45 -08:00
extent.c
hfs_fs.h [PATCH] mark address_space_operations const 2006-06-28 14:59:04 -07:00
hfs.h [PATCH] extend the set of "__attribute__" shortcut macros 2007-02-11 10:51:35 -08:00
inode.c [PATCH] struct path: convert hfs 2006-12-08 08:28:45 -08:00
Makefile
mdb.c [PATCH] hfs: cleanup HFS prints 2006-01-18 19:20:23 -08:00
part_tbl.c
string.c
super.c [PATCH] slab: remove kmem_cache_t 2006-12-07 08:39:25 -08:00
sysdep.c
trans.c