fb.h 1.8 KB
Newer Older
1
/* arch/arm/mach-s3c2410/include/mach/fb.h
2 3 4 5 6 7 8 9 10 11 12 13 14
 *
 * Copyright (c) 2004 Arnaud Patard <arnaud.patard@rtp-net.org>
 *
 * Inspired by pxafb.h
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 as
 * published by the Free Software Foundation.
*/

#ifndef __ASM_ARM_FB_H
#define __ASM_ARM_FB_H

15
#include <mach/regs-lcd.h>
16 17 18 19 20 21 22 23 24

struct s3c2410fb_hw {
	unsigned long	lcdcon1;
	unsigned long	lcdcon2;
	unsigned long	lcdcon3;
	unsigned long	lcdcon4;
	unsigned long	lcdcon5;
};

K
Krzysztof Helt 已提交
25 26 27 28
/* LCD description */
struct s3c2410fb_display {
	/* LCD type */
	unsigned type;
29

30
	/* Screen size */
K
Krzysztof Helt 已提交
31 32
	unsigned short width;
	unsigned short height;
33 34

	/* Screen info */
K
Krzysztof Helt 已提交
35 36 37
	unsigned short xres;
	unsigned short yres;
	unsigned short bpp;
38

39
	unsigned pixclock;		/* pixclock in picoseconds */
40 41 42 43 44 45 46
	unsigned short left_margin;  /* value in pixels (TFT) or HCLKs (STN) */
	unsigned short right_margin; /* value in pixels (TFT) or HCLKs (STN) */
	unsigned short hsync_len;    /* value in pixels (TFT) or HCLKs (STN) */
	unsigned short upper_margin;	/* value in lines (TFT) or 0 (STN) */
	unsigned short lower_margin;	/* value in lines (TFT) or 0 (STN) */
	unsigned short vsync_len;	/* value in lines (TFT) or 0 (STN) */

47
	/* lcd configuration registers */
48
	unsigned long	lcdcon5;
K
Krzysztof Helt 已提交
49 50 51 52 53 54 55
};

struct s3c2410fb_mach_info {

	struct s3c2410fb_display *displays;	/* attached diplays info */
	unsigned num_displays;			/* number of defined displays */
	unsigned default_display;
56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71

	/* GPIOs */

	unsigned long	gpcup;
	unsigned long	gpcup_mask;
	unsigned long	gpccon;
	unsigned long	gpccon_mask;
	unsigned long	gpdup;
	unsigned long	gpdup_mask;
	unsigned long	gpdcon;
	unsigned long	gpdcon_mask;

	/* lpc3600 control register */
	unsigned long	lpcsel;
};

72
extern void __init s3c24xx_fb_set_platdata(struct s3c2410fb_mach_info *);
73 74

#endif /* __ASM_ARM_FB_H */