summaryrefslogtreecommitdiff
path: root/include/linux/fb.h
diff options
context:
space:
mode:
authorJeff Garzik <jgarzik@redhat.com>2004-02-17 10:03:31 -0500
committerJeff Garzik <jgarzik@redhat.com>2004-02-17 10:03:31 -0500
commit0b37a9199bf44bba96aa24b9edbc1c2bb72bec1d (patch)
treeaad525268a3f61a36ecedb66078ab9b0902272c6 /include/linux/fb.h
parent0c92609a946c935ca95af41f13e999dca5eec42e (diff)
parentd6c561cedcbd025198ce21731ccc1eae70e10a3d (diff)
Hand-merge pc300_tty.c conflicts with netdev.
Diffstat (limited to 'include/linux/fb.h')
-rw-r--r--include/linux/fb.h30
1 files changed, 23 insertions, 7 deletions
diff --git a/include/linux/fb.h b/include/linux/fb.h
index e6a2053fbd51..574808f1450d 100644
--- a/include/linux/fb.h
+++ b/include/linux/fb.h
@@ -340,6 +340,24 @@ struct device;
struct file;
/*
+ * Register/unregister for framebuffer events
+ */
+
+/* The resolution of the passed in fb_info about to change */
+#define FB_EVENT_MODE_CHANGE 0x01
+/* The display on this fb_info is beeing suspended, no access to the
+ * framebuffer is allowed any more after that call returns
+ */
+#define FB_EVENT_SUSPEND 0x02
+/* The display on this fb_info was resumed, you can restore the display
+ * if you own it
+ */
+#define FB_EVENT_RESUME 0x03
+
+extern int fb_register_client(struct notifier_block *nb);
+extern int fb_unregister_client(struct notifier_block *nb);
+
+/*
* Pixmap structure definition
*
* The purpose of this structure is to translate data
@@ -363,8 +381,6 @@ struct fb_pixmap {
/* access methods */
void (*outbuf)(u8 *dst, u8 *addr, unsigned int size);
u8 (*inbuf) (u8 *addr);
- spinlock_t lock; /* spinlock */
- atomic_t count;
};
/*
@@ -448,8 +464,10 @@ struct fb_info {
char *screen_base; /* Virtual address */
struct vc_data *display_fg; /* Console visible on this display */
int currcon; /* Current VC. */
- struct class_device class_dev; /* Sysfs data */
void *pseudo_palette; /* Fake palette of 16 colors */
+#define FBINFO_STATE_RUNNING 0
+#define FBINFO_STATE_SUSPENDED 1
+ u32 state; /* Hardware state i.e suspend */
/* From here on everything is device dependent */
void *par;
};
@@ -476,7 +494,7 @@ struct fb_info {
#define fb_writeq sbus_writeq
#define fb_memset sbus_memset_io
-#elif defined(__i386__) || defined(__alpha__) || defined(__x86_64__) || defined(__hppa__)
+#elif defined(__i386__) || defined(__alpha__) || defined(__x86_64__) || defined(__hppa__) || defined(__sh__)
#define fb_readb __raw_readb
#define fb_readw __raw_readw
@@ -526,15 +544,13 @@ extern void move_buf_unaligned(struct fb_info *info, u8 * dst, u8 * src,
u32 idx);
extern void move_buf_aligned(struct fb_info *info, u8 * dst, u8 * src,
u32 d_pitch, u32 s_pitch, u32 height);
+extern void fb_set_suspend(struct fb_info *info, int state);
extern struct fb_info *registered_fb[FB_MAX];
extern int num_registered_fb;
/* drivers/video/fbsysfs.c */
extern struct fb_info *framebuffer_alloc(size_t size, struct device *dev);
extern void framebuffer_release(struct fb_info *info);
-extern int fb_add_class_device(struct fb_info *info);
-
-extern struct class fb_class;
/* drivers/video/fbmon.c */
#define FB_MAXTIMINGS 0