Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

at v4.13-rc2 75 lines 1.9 kB view raw
1/* 2 * LCD panel support for the TI OMAP1510 Innovator board 3 * 4 * Copyright (C) 2004 Nokia Corporation 5 * Author: Imre Deak <imre.deak@nokia.com> 6 * 7 * This program is free software; you can redistribute it and/or modify it 8 * under the terms of the GNU General Public License as published by the 9 * Free Software Foundation; either version 2 of the License, or (at your 10 * option) any later version. 11 * 12 * This program is distributed in the hope that it will be useful, but 13 * WITHOUT ANY WARRANTY; without even the implied warranty of 14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 15 * General Public License for more details. 16 * 17 * You should have received a copy of the GNU General Public License along 18 * with this program; if not, write to the Free Software Foundation, Inc., 19 * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 20 */ 21 22#include <linux/module.h> 23#include <linux/platform_device.h> 24#include <linux/io.h> 25 26#include <mach/hardware.h> 27 28#include "omapfb.h" 29 30static int innovator1510_panel_enable(struct lcd_panel *panel) 31{ 32 __raw_writeb(0x7, OMAP1510_FPGA_LCD_PANEL_CONTROL); 33 return 0; 34} 35 36static void innovator1510_panel_disable(struct lcd_panel *panel) 37{ 38 __raw_writeb(0x0, OMAP1510_FPGA_LCD_PANEL_CONTROL); 39} 40 41static struct lcd_panel innovator1510_panel = { 42 .name = "inn1510", 43 .config = OMAP_LCDC_PANEL_TFT, 44 45 .bpp = 16, 46 .data_lines = 16, 47 .x_res = 240, 48 .y_res = 320, 49 .pixel_clock = 12500, 50 .hsw = 40, 51 .hfp = 40, 52 .hbp = 72, 53 .vsw = 1, 54 .vfp = 1, 55 .vbp = 0, 56 .pcd = 12, 57 58 .enable = innovator1510_panel_enable, 59 .disable = innovator1510_panel_disable, 60}; 61 62static int innovator1510_panel_probe(struct platform_device *pdev) 63{ 64 omapfb_register_panel(&innovator1510_panel); 65 return 0; 66} 67 68static struct platform_driver innovator1510_panel_driver = { 69 .probe = innovator1510_panel_probe, 70 .driver = { 71 .name = "lcd_inn1510", 72 }, 73}; 74 75module_platform_driver(innovator1510_panel_driver);