aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-m68k
Commit message (Expand)AuthorAge
* proc: move /proc/hardware to m68k-specific codeAlexey Dobriyan2008-10-23
* Merge git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6Linus Torvalds2008-10-20
|\
| * ide: remove M68K_IDE_SWAPW define from <asm-m68k/ide.h>Bartlomiej Zolnierkiewicz2008-10-17
* | container freezer: add TIF_FREEZE flag to all architecturesMatt Helsley2008-10-20
|/
* [PATCH] remove unused ibcs2/PER_SVR4 in SET_PERSONALITYMartin Schwidefsky2008-10-16
* m68k: remove the dead PCI codeAdrian Bunk2008-10-14
* m68k: Remove the broken Hades supportAdrian Bunk2008-10-14
* m68k: <asm/pci.h> needs <asm-generic/pci-dma-compat.h>Geert Uytterhoeven2008-10-14
* m68k: Add missing dma_sync_single_range_for_{cpu,device}()Geert Uytterhoeven2008-10-14
* m68k{,nommu}: Wire up new system callsGeert Uytterhoeven2008-08-11
* m68k: some asm-sparc include files movedStephen Rothwell2008-08-04
* [PATCH] kill altrootAl Viro2008-07-26
* dma-mapping: add the device argument to dma_mapping_error()FUJITA Tomonori2008-07-26
* Merge git://git.infradead.org/~dwmw2/random-2.6Linus Torvalds2008-07-25
|\
| * remove dummy asm/kvm.h filesAdrian Bunk2008-07-25
* | clean up duplicated alloc/free_thread_infoFUJITA Tomonori2008-07-25
|/
* Merge git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6Linus Torvalds2008-07-24
|\
| * ide: define MAX_HWIFS in <linux/ide.h>Bartlomiej Zolnierkiewicz2008-07-24
* | Merge branch 'semaphore' of git://git.kernel.org/pub/scm/linux/kernel/git/wil...Linus Torvalds2008-07-24
|\ \
| * | Remove asm/semaphore.hMatthew Wilcox2008-07-24
| |/
* / PAGE_ALIGN(): correctly handle 64-bit values on 32-bit architecturesAndrea Righi2008-07-24
|/
* m68k: remove stale ARCH_SUN4 #defineAdrian Bunk2008-07-20
* m68k/sun3/: possible cleanupsAdrian Bunk2008-07-20
* m68k/mac/: possible cleanupsAdrian Bunk2008-07-20
* m68k/amiga/: possible cleanupsAdrian Bunk2008-07-20
* m68k: remove AP1000 codeAdrian Bunk2008-07-20
* m68k: Allow no CPU/platform type for allnoconfigGeert Uytterhoeven2008-07-20
* m68k: remove CVS keywordsAdrian Bunk2008-07-20
* m68k: Add ext2_find_{first,next}_bit() for ext4Aneesh Kumar K.V2008-06-12
* m68k: Prefix ISA type with ISA_TYPE_Geert Uytterhoeven2008-05-18
* m68k: export m68k_mmutypeGeert Uytterhoeven2008-05-18
* m68k: Make gcc aware that BUG() does not returnGeert Uytterhoeven2008-05-18
* m68k: Convert access_ok() to an inline functionGeert Uytterhoeven2008-05-18
* m68k: remove old mac_esp cruftFinn Thain2008-05-05
* m68k: types: use <asm-generic/int-*.h> for the m68k architectureH. Peter Anvin2008-05-02
* rename div64_64 to div64_u64Roman Zippel2008-05-01
* kernel: Move arches to use common unaligned accessHarvey Harrison2008-04-29
* mm: introduce pte_special pte bitNick Piggin2008-04-28
* Generic semaphore implementationMatthew Wilcox2008-04-17
* kvm: provide kvm.h for all architecture: fixes headers_installChristian Borntraeger2008-04-02
* m68k{,nommu}: Wire up new timerfd syscallsGeert Uytterhoeven2008-03-04
* CONFIG_HIGHPTE vs. sub-page page tables.Martin Schwidefsky2008-02-08
* avoid overflows in kernel/time.cH. Peter Anvin2008-02-08
* asm-*/posix_types.h: scrub __GLIBC__Mike Frysinger2008-02-08
* aout: suppress A.OUT library support if !CONFIG_ARCH_SUPPORTS_AOUTDavid Howells2008-02-08
* aout: move STACK_TOP[_MAX] to asm/processor.hDavid Howells2008-02-08
* m68k: kill page walker compile warningGeert Uytterhoeven2008-02-07
* Add cmpxchg_local to m86kMathieu Desnoyers2008-02-07
* Sanitize the type of struct user.u_ar0H. Peter Anvin2008-02-07
* Cleanup asm/{elf,page,user}.h: #ifdef __KERNEL__ is no longer neededKirill A. Shutemov2008-02-07
.com> 2008-03-31 05:40:07 -0400 [GFS2] Allocate gfs2_rgrpd from slab memory' href='/cgit/cgit.cgi/litmus-rt.git/commit/fs/gfs2/util.h?h=v2.6.34-rc3&id=6bdd9be628fa5f4dd14eb89ebddc12840d684277'>6bdd9be628fa
b3b94faa5fe5
b3b94faa5fe5














da755fdb4144
b3b94faa5fe5


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170

                                                                       
                                                              


                                                                        
                                               




                      
                   



















                                                                      
                        








                                                                                
                                                                      






                                                                            
                                                                      





                                                                        
                                                      





                                                                              
                                                           





                                                                              
                                                            











                                                                            
                                              






                                                                            
                                                            


                                                                        
                                           




                                                               
                                                 



                                                                            
                                              
                                         


                                                                            






                                                                         
                                                                        
 

                                                                      


                                                   

                                            






                                                               
                                                     





                                                                            
                                                              

 


                                              
                                            
 














                                                                   
                                                           


                           
/*
 * Copyright (C) Sistina Software, Inc.  1997-2003 All rights reserved.
 * Copyright (C) 2004-2006 Red Hat, Inc.  All rights reserved.
 *
 * This copyrighted material is made available to anyone wishing to use,
 * modify, copy, or redistribute it subject to the terms and conditions
 * of the GNU General Public License version 2.
 */

#ifndef __UTIL_DOT_H__
#define __UTIL_DOT_H__

#include "incore.h"

#define fs_printk(level, fs, fmt, arg...) \
	printk(level "GFS2: fsid=%s: " fmt , (fs)->sd_fsname , ## arg)

#define fs_info(fs, fmt, arg...) \
	fs_printk(KERN_INFO , fs , fmt , ## arg)

#define fs_warn(fs, fmt, arg...) \
	fs_printk(KERN_WARNING , fs , fmt , ## arg)

#define fs_err(fs, fmt, arg...) \
	fs_printk(KERN_ERR, fs , fmt , ## arg)


void gfs2_assert_i(struct gfs2_sbd *sdp);

#define gfs2_assert(sdp, assertion) \
do { \
	if (unlikely(!(assertion))) { \
		gfs2_assert_i(sdp); \
		BUG(); \
        } \
} while (0)


int gfs2_assert_withdraw_i(struct gfs2_sbd *sdp, char *assertion,
			   const char *function, char *file, unsigned int line);

#define gfs2_assert_withdraw(sdp, assertion) \
((likely(assertion)) ? 0 : gfs2_assert_withdraw_i((sdp), #assertion, \
					__func__, __FILE__, __LINE__))


int gfs2_assert_warn_i(struct gfs2_sbd *sdp, char *assertion,
		       const char *function, char *file, unsigned int line);

#define gfs2_assert_warn(sdp, assertion) \
((likely(assertion)) ? 0 : gfs2_assert_warn_i((sdp), #assertion, \
					__func__, __FILE__, __LINE__))


int gfs2_consist_i(struct gfs2_sbd *sdp, int cluster_wide,
		   const char *function, char *file, unsigned int line);

#define gfs2_consist(sdp) \
gfs2_consist_i((sdp), 0, __func__, __FILE__, __LINE__)


int gfs2_consist_inode_i(struct gfs2_inode *ip, int cluster_wide,
			 const char *function, char *file, unsigned int line);

#define gfs2_consist_inode(ip) \
gfs2_consist_inode_i((ip), 0, __func__, __FILE__, __LINE__)


int gfs2_consist_rgrpd_i(struct gfs2_rgrpd *rgd, int cluster_wide,
			 const char *function, char *file, unsigned int line);

#define gfs2_consist_rgrpd(rgd) \
gfs2_consist_rgrpd_i((rgd), 0, __func__, __FILE__, __LINE__)


int gfs2_meta_check_ii(struct gfs2_sbd *sdp, struct buffer_head *bh,
		       const char *type, const char *function,
		       char *file, unsigned int line);

static inline int gfs2_meta_check_i(struct gfs2_sbd *sdp,
				    struct buffer_head *bh,
				    const char *function,
				    char *file, unsigned int line)
{
	struct gfs2_meta_header *mh = (struct gfs2_meta_header *)bh->b_data;
	u32 magic = be32_to_cpu(mh->mh_magic);
	if (unlikely(magic != GFS2_MAGIC))
		return gfs2_meta_check_ii(sdp, bh, "magic number", function,
					  file, line);
	return 0;
}

#define gfs2_meta_check(sdp, bh) \
gfs2_meta_check_i((sdp), (bh), __func__, __FILE__, __LINE__)


int gfs2_metatype_check_ii(struct gfs2_sbd *sdp, struct buffer_head *bh,
			   u16 type, u16 t,
			   const char *function,
			   char *file, unsigned int line);

static inline int gfs2_metatype_check_i(struct gfs2_sbd *sdp,
					struct buffer_head *bh,
					u16 type,
					const char *function,
					char *file, unsigned int line)
{
	struct gfs2_meta_header *mh = (struct gfs2_meta_header *)bh->b_data;
	u32 magic = be32_to_cpu(mh->mh_magic);
	u16 t = be32_to_cpu(mh->mh_type);
	if (unlikely(magic != GFS2_MAGIC))
		return gfs2_meta_check_ii(sdp, bh, "magic number", function,
					  file, line);
        if (unlikely(t != type))
		return gfs2_metatype_check_ii(sdp, bh, type, t, function,
					      file, line);
	return 0;
}

#define gfs2_metatype_check(sdp, bh, type) \
gfs2_metatype_check_i((sdp), (bh), (type), __func__, __FILE__, __LINE__)

static inline void gfs2_metatype_set(struct buffer_head *bh, u16 type,
				     u16 format)
{
	struct gfs2_meta_header *mh;
	mh = (struct gfs2_meta_header *)bh->b_data;
	mh->mh_type = cpu_to_be32(type);
	mh->mh_format = cpu_to_be32(format);
}


int gfs2_io_error_i(struct gfs2_sbd *sdp, const char *function,
		    char *file, unsigned int line);

#define gfs2_io_error(sdp) \
gfs2_io_error_i((sdp), __func__, __FILE__, __LINE__);


int gfs2_io_error_bh_i(struct gfs2_sbd *sdp, struct buffer_head *bh,
		       const char *function, char *file, unsigned int line);

#define gfs2_io_error_bh(sdp, bh) \
gfs2_io_error_bh_i((sdp), (bh), __func__, __FILE__, __LINE__);


extern struct kmem_cache *gfs2_glock_cachep;
extern struct kmem_cache *gfs2_inode_cachep;
extern struct kmem_cache *gfs2_bufdata_cachep;
extern struct kmem_cache *gfs2_rgrpd_cachep;

static inline unsigned int gfs2_tune_get_i(struct gfs2_tune *gt,
					   unsigned int *p)
{
	unsigned int x;
	spin_lock(&gt->gt_spin);
	x = *p;
	spin_unlock(&gt->gt_spin);
	return x;
}

#define gfs2_tune_get(sdp, field) \
gfs2_tune_get_i(&(sdp)->sd_tune, &(sdp)->sd_tune.field)

void gfs2_icbit_munge(struct gfs2_sbd *sdp, unsigned char **bitmap,
		      unsigned int bit, int new_value);
int gfs2_lm_withdraw(struct gfs2_sbd *sdp, char *fmt, ...);

#endif /* __UTIL_DOT_H__ */