patch-2.4.21 linux-2.4.21/include/asm-ia64/sn/sgi.h
Next file: linux-2.4.21/include/asm-ia64/sn/simulator.h
Previous file: linux-2.4.21/include/asm-ia64/sn/rw_mmr.h
Back to the patch index
Back to the overall index
- Lines: 115
- Date:
2003-06-13 07:51:38.000000000 -0700
- Orig file:
linux-2.4.20/include/asm-ia64/sn/sgi.h
- Orig date:
2002-08-02 17:39:45.000000000 -0700
diff -urN linux-2.4.20/include/asm-ia64/sn/sgi.h linux-2.4.21/include/asm-ia64/sn/sgi.h
@@ -18,82 +18,6 @@
#include <linux/mm.h>
#include <linux/devfs_fs_kernel.h>
-// This devfs stuff needs a better home .....
-
-struct directory_type
-{
- struct devfs_entry *first;
- struct devfs_entry *last;
- unsigned int num_removable;
-};
-
-struct file_type
-{
- unsigned long size;
-};
-
-struct device_type
-{
- unsigned short major;
- unsigned short minor;
-};
-
-struct fcb_type /* File, char, block type */
-{
- uid_t default_uid;
- gid_t default_gid;
- void *ops;
- union
- {
- struct file_type file;
- struct device_type device;
- }
- u;
- unsigned char auto_owner:1;
- unsigned char aopen_notify:1;
- unsigned char removable:1; /* Belongs in device_type, but save space */
- unsigned char open:1; /* Not entirely correct */
-};
-
-struct symlink_type
-{
- unsigned int length; /* Not including the NULL-termimator */
- char *linkname; /* This is NULL-terminated */
-};
-
-struct fifo_type
-{
- uid_t uid;
- gid_t gid;
-};
-
-struct devfs_entry
-{
- void *info;
- union
- {
- struct directory_type dir;
- struct fcb_type fcb;
- struct symlink_type symlink;
- struct fifo_type fifo;
- }
- u;
- struct devfs_entry *prev; /* Previous entry in the parent directory */
- struct devfs_entry *next; /* Next entry in the parent directory */
- struct devfs_entry *parent; /* The parent directory */
- struct devfs_entry *slave; /* Another entry to unregister */
- struct devfs_inode *first_inode;
- struct devfs_inode *last_inode;
- umode_t mode;
- unsigned short namelen; /* I think 64k+ filenames are a way off... */
- unsigned char registered:1;
- unsigned char show_unreg:1;
- unsigned char hide:1;
- unsigned char no_persistence /*:1*/;
- char name[1]; /* This is just a dummy: the allocated array is
- bigger. This is NULL-terminated */
-};
-
typedef int64_t __psint_t; /* needed by klgraph.c */
typedef enum { B_FALSE, B_TRUE } boolean_t;
@@ -223,6 +147,31 @@
#define cpu_enabled(cpu) (1)
#endif
+/* print_register() defs */
+
+/*
+ * register values
+ * map between numeric values and symbolic values
+ */
+struct reg_values {
+ unsigned long long rv_value;
+ char *rv_name;
+};
+
+/*
+ * register descriptors are used for formatted prints of register values
+ * rd_mask and rd_shift must be defined, other entries may be null
+ */
+struct reg_desc {
+ unsigned long long rd_mask; /* mask to extract field */
+ int rd_shift; /* shift for extracted value, - >>, + << */
+ char *rd_name; /* field name */
+ char *rd_format; /* format to print field */
+ struct reg_values *rd_values; /* symbolic names of values */
+};
+
+extern void print_register(unsigned long long, struct reg_desc *);
+
#include <asm/sn/hack.h> /* for now */
#endif /* _ASM_IA64_SN_SGI_H */
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)