arcfb.c 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682
  1. /*
  2. * linux/drivers/video/arcfb.c -- FB driver for Arc monochrome LCD board
  3. *
  4. * Copyright (C) 2005, Jaya Kumar <jayalk@intworks.biz>
  5. * http://www.intworks.biz/arclcd
  6. *
  7. * This file is subject to the terms and conditions of the GNU General Public
  8. * License. See the file COPYING in the main directory of this archive for
  9. * more details.
  10. *
  11. * Layout is based on skeletonfb.c by James Simmons and Geert Uytterhoeven.
  12. *
  13. * This driver was written to be used with the Arc LCD board. Arc uses a
  14. * set of KS108 chips that control individual 64x64 LCD matrices. The board
  15. * can be paneled in a variety of setups such as 2x1=128x64, 4x4=256x256 and
  16. * so on. The interface between the board and the host is TTL based GPIO. The
  17. * GPIO requirements are 8 writable data lines and 4+n lines for control. On a
  18. * GPIO-less system, the board can be tested by connecting the respective sigs
  19. * up to a parallel port connector. The driver requires the IO addresses for
  20. * data and control GPIO at load time. It is unable to probe for the
  21. * existence of the LCD so it must be told at load time whether it should
  22. * be enabled or not.
  23. *
  24. * Todo:
  25. * - testing with 4x4
  26. * - testing with interrupt hw
  27. *
  28. * General notes:
  29. * - User must set tuhold. It's in microseconds. According to the 108 spec,
  30. * the hold time is supposed to be at least 1 microsecond.
  31. * - User must set num_cols=x num_rows=y, eg: x=2 means 128
  32. * - User must set arcfb_enable=1 to enable it
  33. * - User must set dio_addr=0xIOADDR cio_addr=0xIOADDR
  34. *
  35. */
  36. #include <linux/module.h>
  37. #include <linux/kernel.h>
  38. #include <linux/errno.h>
  39. #include <linux/string.h>
  40. #include <linux/mm.h>
  41. #include <linux/tty.h>
  42. #include <linux/slab.h>
  43. #include <linux/vmalloc.h>
  44. #include <linux/delay.h>
  45. #include <linux/interrupt.h>
  46. #include <linux/fb.h>
  47. #include <linux/init.h>
  48. #include <linux/arcfb.h>
  49. #include <linux/platform_device.h>
  50. #include <asm/uaccess.h>
  51. #define floor8(a) (a&(~0x07))
  52. #define floorXres(a,xres) (a&(~(xres - 1)))
  53. #define iceil8(a) (((int)((a+7)/8))*8)
  54. #define ceil64(a) (a|0x3F)
  55. #define ceilXres(a,xres) (a|(xres - 1))
  56. /* ks108 chipset specific defines and code */
  57. #define KS_SET_DPY_START_LINE 0xC0
  58. #define KS_SET_PAGE_NUM 0xB8
  59. #define KS_SET_X 0x40
  60. #define KS_CEHI 0x01
  61. #define KS_CELO 0x00
  62. #define KS_SEL_CMD 0x08
  63. #define KS_SEL_DATA 0x00
  64. #define KS_DPY_ON 0x3F
  65. #define KS_DPY_OFF 0x3E
  66. #define KS_INTACK 0x40
  67. #define KS_CLRINT 0x02
  68. struct arcfb_par {
  69. unsigned long dio_addr;
  70. unsigned long cio_addr;
  71. unsigned long c2io_addr;
  72. atomic_t ref_count;
  73. unsigned char cslut[9];
  74. struct fb_info *info;
  75. unsigned int irq;
  76. spinlock_t lock;
  77. };
  78. static struct fb_fix_screeninfo arcfb_fix __initdata = {
  79. .id = "arcfb",
  80. .type = FB_TYPE_PACKED_PIXELS,
  81. .visual = FB_VISUAL_MONO01,
  82. .xpanstep = 0,
  83. .ypanstep = 1,
  84. .ywrapstep = 0,
  85. .accel = FB_ACCEL_NONE,
  86. };
  87. static struct fb_var_screeninfo arcfb_var __initdata = {
  88. .xres = 128,
  89. .yres = 64,
  90. .xres_virtual = 128,
  91. .yres_virtual = 64,
  92. .bits_per_pixel = 1,
  93. .nonstd = 1,
  94. };
  95. static unsigned long num_cols;
  96. static unsigned long num_rows;
  97. static unsigned long dio_addr;
  98. static unsigned long cio_addr;
  99. static unsigned long c2io_addr;
  100. static unsigned long splashval;
  101. static unsigned long tuhold;
  102. static unsigned int nosplash;
  103. static unsigned int arcfb_enable;
  104. static unsigned int irq;
  105. static DECLARE_WAIT_QUEUE_HEAD(arcfb_waitq);
  106. static void ks108_writeb_ctl(struct arcfb_par *par,
  107. unsigned int chipindex, unsigned char value)
  108. {
  109. unsigned char chipselval = par->cslut[chipindex];
  110. outb(chipselval|KS_CEHI|KS_SEL_CMD, par->cio_addr);
  111. outb(value, par->dio_addr);
  112. udelay(tuhold);
  113. outb(chipselval|KS_CELO|KS_SEL_CMD, par->cio_addr);
  114. }
  115. static void ks108_writeb_mainctl(struct arcfb_par *par, unsigned char value)
  116. {
  117. outb(value, par->cio_addr);
  118. udelay(tuhold);
  119. }
  120. static unsigned char ks108_readb_ctl2(struct arcfb_par *par)
  121. {
  122. return inb(par->c2io_addr);
  123. }
  124. static void ks108_writeb_data(struct arcfb_par *par,
  125. unsigned int chipindex, unsigned char value)
  126. {
  127. unsigned char chipselval = par->cslut[chipindex];
  128. outb(chipselval|KS_CEHI|KS_SEL_DATA, par->cio_addr);
  129. outb(value, par->dio_addr);
  130. udelay(tuhold);
  131. outb(chipselval|KS_CELO|KS_SEL_DATA, par->cio_addr);
  132. }
  133. static void ks108_set_start_line(struct arcfb_par *par,
  134. unsigned int chipindex, unsigned char y)
  135. {
  136. ks108_writeb_ctl(par, chipindex, KS_SET_DPY_START_LINE|y);
  137. }
  138. static void ks108_set_yaddr(struct arcfb_par *par,
  139. unsigned int chipindex, unsigned char y)
  140. {
  141. ks108_writeb_ctl(par, chipindex, KS_SET_PAGE_NUM|y);
  142. }
  143. static void ks108_set_xaddr(struct arcfb_par *par,
  144. unsigned int chipindex, unsigned char x)
  145. {
  146. ks108_writeb_ctl(par, chipindex, KS_SET_X|x);
  147. }
  148. static void ks108_clear_lcd(struct arcfb_par *par, unsigned int chipindex)
  149. {
  150. int i,j;
  151. for (i = 0; i <= 8; i++) {
  152. ks108_set_yaddr(par, chipindex, i);
  153. ks108_set_xaddr(par, chipindex, 0);
  154. for (j = 0; j < 64; j++) {
  155. ks108_writeb_data(par, chipindex,
  156. (unsigned char) splashval);
  157. }
  158. }
  159. }
  160. /* main arcfb functions */
  161. static int arcfb_open(struct fb_info *info, int user)
  162. {
  163. struct arcfb_par *par = info->par;
  164. atomic_inc(&par->ref_count);
  165. return 0;
  166. }
  167. static int arcfb_release(struct fb_info *info, int user)
  168. {
  169. struct arcfb_par *par = info->par;
  170. int count = atomic_read(&par->ref_count);
  171. if (!count)
  172. return -EINVAL;
  173. atomic_dec(&par->ref_count);
  174. return 0;
  175. }
  176. static int arcfb_pan_display(struct fb_var_screeninfo *var,
  177. struct fb_info *info)
  178. {
  179. int i;
  180. struct arcfb_par *par = info->par;
  181. if ((var->vmode & FB_VMODE_YWRAP) && (var->yoffset < 64)
  182. && (info->var.yres <= 64)) {
  183. for (i = 0; i < num_cols; i++) {
  184. ks108_set_start_line(par, i, var->yoffset);
  185. }
  186. info->var.yoffset = var->yoffset;
  187. return 0;
  188. }
  189. return -EINVAL;
  190. }
  191. static irqreturn_t arcfb_interrupt(int vec, void *dev_instance,
  192. struct pt_regs *regs)
  193. {
  194. struct fb_info *info = dev_instance;
  195. unsigned char ctl2status;
  196. struct arcfb_par *par = info->par;
  197. ctl2status = ks108_readb_ctl2(par);
  198. if (!(ctl2status & KS_INTACK)) /* not arc generated interrupt */
  199. return IRQ_NONE;
  200. ks108_writeb_mainctl(par, KS_CLRINT);
  201. spin_lock(&par->lock);
  202. if (waitqueue_active(&arcfb_waitq)) {
  203. wake_up(&arcfb_waitq);
  204. }
  205. spin_unlock(&par->lock);
  206. return IRQ_HANDLED;
  207. }
  208. /*
  209. * here we handle a specific page on the lcd. the complexity comes from
  210. * the fact that the fb is laidout in 8xX vertical columns. we extract
  211. * each write of 8 vertical pixels. then we shift out as we move along
  212. * X. That's what rightshift does. bitmask selects the desired input bit.
  213. */
  214. static void arcfb_lcd_update_page(struct arcfb_par *par, unsigned int upper,
  215. unsigned int left, unsigned int right, unsigned int distance)
  216. {
  217. unsigned char *src;
  218. unsigned int xindex, yindex, chipindex, linesize;
  219. int i, count;
  220. unsigned char val;
  221. unsigned char bitmask, rightshift;
  222. xindex = left >> 6;
  223. yindex = upper >> 6;
  224. chipindex = (xindex + (yindex*num_cols));
  225. ks108_set_yaddr(par, chipindex, upper/8);
  226. linesize = par->info->var.xres/8;
  227. src = par->info->screen_base + (left/8) + (upper * linesize);
  228. ks108_set_xaddr(par, chipindex, left);
  229. bitmask=1;
  230. rightshift=0;
  231. while (left <= right) {
  232. val = 0;
  233. for (i = 0; i < 8; i++) {
  234. if ( i > rightshift) {
  235. val |= (*(src + (i*linesize)) & bitmask)
  236. << (i - rightshift);
  237. } else {
  238. val |= (*(src + (i*linesize)) & bitmask)
  239. >> (rightshift - i);
  240. }
  241. }
  242. ks108_writeb_data(par, chipindex, val);
  243. left++;
  244. count++;
  245. if (bitmask == 0x80) {
  246. bitmask = 1;
  247. src++;
  248. rightshift=0;
  249. } else {
  250. bitmask <<= 1;
  251. rightshift++;
  252. }
  253. }
  254. }
  255. /*
  256. * here we handle the entire vertical page of the update. we write across
  257. * lcd chips. update_page uses the upper/left values to decide which
  258. * chip to select for the right. upper is needed for setting the page
  259. * desired for the write.
  260. */
  261. static void arcfb_lcd_update_vert(struct arcfb_par *par, unsigned int top,
  262. unsigned int bottom, unsigned int left, unsigned int right)
  263. {
  264. unsigned int distance, upper, lower;
  265. distance = (bottom - top) + 1;
  266. upper = top;
  267. lower = top + 7;
  268. while (distance > 0) {
  269. distance -= 8;
  270. arcfb_lcd_update_page(par, upper, left, right, 8);
  271. upper = lower + 1;
  272. lower = upper + 7;
  273. }
  274. }
  275. /*
  276. * here we handle horizontal blocks for the update. update_vert will
  277. * handle spaning multiple pages. we break out each horizontal
  278. * block in to individual blocks no taller than 64 pixels.
  279. */
  280. static void arcfb_lcd_update_horiz(struct arcfb_par *par, unsigned int left,
  281. unsigned int right, unsigned int top, unsigned int h)
  282. {
  283. unsigned int distance, upper, lower;
  284. distance = h;
  285. upper = floor8(top);
  286. lower = min(upper + distance - 1, ceil64(upper));
  287. while (distance > 0) {
  288. distance -= ((lower - upper) + 1 );
  289. arcfb_lcd_update_vert(par, upper, lower, left, right);
  290. upper = lower + 1;
  291. lower = min(upper + distance - 1, ceil64(upper));
  292. }
  293. }
  294. /*
  295. * here we start the process of spliting out the fb update into
  296. * individual blocks of pixels. we end up spliting into 64x64 blocks
  297. * and finally down to 64x8 pages.
  298. */
  299. static void arcfb_lcd_update(struct arcfb_par *par, unsigned int dx,
  300. unsigned int dy, unsigned int w, unsigned int h)
  301. {
  302. unsigned int left, right, distance, y;
  303. /* align the request first */
  304. y = floor8(dy);
  305. h += dy - y;
  306. h = iceil8(h);
  307. distance = w;
  308. left = dx;
  309. right = min(left + w - 1, ceil64(left));
  310. while (distance > 0) {
  311. arcfb_lcd_update_horiz(par, left, right, y, h);
  312. distance -= ((right - left) + 1);
  313. left = right + 1;
  314. right = min(left + distance - 1, ceil64(left));
  315. }
  316. }
  317. static void arcfb_fillrect(struct fb_info *info,
  318. const struct fb_fillrect *rect)
  319. {
  320. struct arcfb_par *par = info->par;
  321. cfb_fillrect(info, rect);
  322. /* update the physical lcd */
  323. arcfb_lcd_update(par, rect->dx, rect->dy, rect->width, rect->height);
  324. }
  325. static void arcfb_copyarea(struct fb_info *info,
  326. const struct fb_copyarea *area)
  327. {
  328. struct arcfb_par *par = info->par;
  329. cfb_copyarea(info, area);
  330. /* update the physical lcd */
  331. arcfb_lcd_update(par, area->dx, area->dy, area->width, area->height);
  332. }
  333. static void arcfb_imageblit(struct fb_info *info, const struct fb_image *image)
  334. {
  335. struct arcfb_par *par = info->par;
  336. cfb_imageblit(info, image);
  337. /* update the physical lcd */
  338. arcfb_lcd_update(par, image->dx, image->dy, image->width,
  339. image->height);
  340. }
  341. static int arcfb_ioctl(struct fb_info *info,
  342. unsigned int cmd, unsigned long arg)
  343. {
  344. void __user *argp = (void __user *)arg;
  345. struct arcfb_par *par = info->par;
  346. unsigned long flags;
  347. switch (cmd) {
  348. case FBIO_WAITEVENT:
  349. {
  350. DEFINE_WAIT(wait);
  351. /* illegal to wait on arc if no irq will occur */
  352. if (!par->irq)
  353. return -EINVAL;
  354. /* wait until the Arc has generated an interrupt
  355. * which will wake us up */
  356. spin_lock_irqsave(&par->lock, flags);
  357. prepare_to_wait(&arcfb_waitq, &wait,
  358. TASK_INTERRUPTIBLE);
  359. spin_unlock_irqrestore(&par->lock, flags);
  360. schedule();
  361. finish_wait(&arcfb_waitq, &wait);
  362. }
  363. case FBIO_GETCONTROL2:
  364. {
  365. unsigned char ctl2;
  366. ctl2 = ks108_readb_ctl2(info->par);
  367. if (copy_to_user(argp, &ctl2, sizeof(ctl2)))
  368. return -EFAULT;
  369. return 0;
  370. }
  371. default:
  372. return -EINVAL;
  373. }
  374. }
  375. /*
  376. * this is the access path from userspace. they can seek and write to
  377. * the fb. it's inefficient for them to do anything less than 64*8
  378. * writes since we update the lcd in each write() anyway.
  379. */
  380. static ssize_t arcfb_write(struct file *file, const char __user *buf, size_t count,
  381. loff_t *ppos)
  382. {
  383. /* modded from epson 1355 */
  384. struct inode *inode;
  385. int fbidx;
  386. struct fb_info *info;
  387. unsigned long p;
  388. int err=-EINVAL;
  389. unsigned int fbmemlength,x,y,w,h, bitppos, startpos, endpos, bitcount;
  390. struct arcfb_par *par;
  391. unsigned int xres;
  392. p = *ppos;
  393. inode = file->f_dentry->d_inode;
  394. fbidx = iminor(inode);
  395. info = registered_fb[fbidx];
  396. par = info->par;
  397. if (!info || !info->screen_base)
  398. return -ENODEV;
  399. xres = info->var.xres;
  400. fbmemlength = (xres * info->var.yres)/8;
  401. if (p > fbmemlength)
  402. return -ENOSPC;
  403. err = 0;
  404. if ((count + p) > fbmemlength) {
  405. count = fbmemlength - p;
  406. err = -ENOSPC;
  407. }
  408. if (count) {
  409. char *base_addr;
  410. base_addr = info->screen_base;
  411. count -= copy_from_user(base_addr + p, buf, count);
  412. *ppos += count;
  413. err = -EFAULT;
  414. }
  415. bitppos = p*8;
  416. startpos = floorXres(bitppos, xres);
  417. endpos = ceilXres((bitppos + (count*8)), xres);
  418. bitcount = endpos - startpos;
  419. x = startpos % xres;
  420. y = startpos / xres;
  421. w = xres;
  422. h = bitcount / xres;
  423. arcfb_lcd_update(par, x, y, w, h);
  424. if (count)
  425. return count;
  426. return err;
  427. }
  428. static struct fb_ops arcfb_ops = {
  429. .owner = THIS_MODULE,
  430. .fb_open = arcfb_open,
  431. .fb_write = arcfb_write,
  432. .fb_release = arcfb_release,
  433. .fb_pan_display = arcfb_pan_display,
  434. .fb_fillrect = arcfb_fillrect,
  435. .fb_copyarea = arcfb_copyarea,
  436. .fb_imageblit = arcfb_imageblit,
  437. .fb_ioctl = arcfb_ioctl,
  438. };
  439. static int __init arcfb_probe(struct platform_device *dev)
  440. {
  441. struct fb_info *info;
  442. int retval = -ENOMEM;
  443. int videomemorysize;
  444. unsigned char *videomemory;
  445. struct arcfb_par *par;
  446. int i;
  447. videomemorysize = (((64*64)*num_cols)*num_rows)/8;
  448. /* We need a flat backing store for the Arc's
  449. less-flat actual paged framebuffer */
  450. if (!(videomemory = vmalloc(videomemorysize)))
  451. return retval;
  452. memset(videomemory, 0, videomemorysize);
  453. info = framebuffer_alloc(sizeof(struct arcfb_par), &dev->dev);
  454. if (!info)
  455. goto err;
  456. info->screen_base = (char __iomem *)videomemory;
  457. info->fbops = &arcfb_ops;
  458. info->var = arcfb_var;
  459. info->fix = arcfb_fix;
  460. par = info->par;
  461. par->info = info;
  462. if (!dio_addr || !cio_addr || !c2io_addr) {
  463. printk(KERN_WARNING "no IO addresses supplied\n");
  464. goto err1;
  465. }
  466. par->dio_addr = dio_addr;
  467. par->cio_addr = cio_addr;
  468. par->c2io_addr = c2io_addr;
  469. par->cslut[0] = 0x00;
  470. par->cslut[1] = 0x06;
  471. info->flags = FBINFO_FLAG_DEFAULT;
  472. spin_lock_init(&par->lock);
  473. retval = register_framebuffer(info);
  474. if (retval < 0)
  475. goto err1;
  476. platform_set_drvdata(dev, info);
  477. if (irq) {
  478. par->irq = irq;
  479. if (request_irq(par->irq, &arcfb_interrupt, SA_SHIRQ,
  480. "arcfb", info)) {
  481. printk(KERN_INFO
  482. "arcfb: Failed req IRQ %d\n", par->irq);
  483. goto err1;
  484. }
  485. }
  486. printk(KERN_INFO
  487. "fb%d: Arc frame buffer device, using %dK of video memory\n",
  488. info->node, videomemorysize >> 10);
  489. /* this inits the lcd but doesn't clear dirty pixels */
  490. for (i = 0; i < num_cols * num_rows; i++) {
  491. ks108_writeb_ctl(par, i, KS_DPY_OFF);
  492. ks108_set_start_line(par, i, 0);
  493. ks108_set_yaddr(par, i, 0);
  494. ks108_set_xaddr(par, i, 0);
  495. ks108_writeb_ctl(par, i, KS_DPY_ON);
  496. }
  497. /* if we were told to splash the screen, we just clear it */
  498. if (!nosplash) {
  499. for (i = 0; i < num_cols * num_rows; i++) {
  500. printk(KERN_INFO "fb%d: splashing lcd %d\n",
  501. info->node, i);
  502. ks108_set_start_line(par, i, 0);
  503. ks108_clear_lcd(par, i);
  504. }
  505. }
  506. return 0;
  507. err1:
  508. framebuffer_release(info);
  509. err:
  510. vfree(videomemory);
  511. return retval;
  512. }
  513. static int arcfb_remove(struct platform_device *dev)
  514. {
  515. struct fb_info *info = platform_get_drvdata(dev);
  516. if (info) {
  517. unregister_framebuffer(info);
  518. vfree(info->screen_base);
  519. framebuffer_release(info);
  520. }
  521. return 0;
  522. }
  523. static struct platform_driver arcfb_driver = {
  524. .probe = arcfb_probe,
  525. .remove = arcfb_remove,
  526. .driver = {
  527. .name = "arcfb",
  528. },
  529. };
  530. static struct platform_device *arcfb_device;
  531. static int __init arcfb_init(void)
  532. {
  533. int ret;
  534. if (!arcfb_enable)
  535. return -ENXIO;
  536. ret = platform_driver_register(&arcfb_driver);
  537. if (!ret) {
  538. arcfb_device = platform_device_alloc("arcfb", 0);
  539. if (arcfb_device) {
  540. ret = platform_device_add(arcfb_device);
  541. } else {
  542. ret = -ENOMEM;
  543. }
  544. if (ret) {
  545. platform_device_put(arcfb_device);
  546. platform_driver_unregister(&arcfb_driver);
  547. }
  548. }
  549. return ret;
  550. }
  551. static void __exit arcfb_exit(void)
  552. {
  553. platform_device_unregister(arcfb_device);
  554. platform_driver_unregister(&arcfb_driver);
  555. }
  556. module_param(num_cols, ulong, 0);
  557. MODULE_PARM_DESC(num_cols, "Num horiz panels, eg: 2 = 128 bit wide");
  558. module_param(num_rows, ulong, 0);
  559. MODULE_PARM_DESC(num_rows, "Num vert panels, eg: 1 = 64 bit high");
  560. module_param(nosplash, uint, 0);
  561. MODULE_PARM_DESC(nosplash, "Disable doing the splash screen");
  562. module_param(arcfb_enable, uint, 0);
  563. MODULE_PARM_DESC(arcfb_enable, "Enable communication with Arc board");
  564. module_param(dio_addr, ulong, 0);
  565. MODULE_PARM_DESC(dio_addr, "IO address for data, eg: 0x480");
  566. module_param(cio_addr, ulong, 0);
  567. MODULE_PARM_DESC(cio_addr, "IO address for control, eg: 0x400");
  568. module_param(c2io_addr, ulong, 0);
  569. MODULE_PARM_DESC(c2io_addr, "IO address for secondary control, eg: 0x408");
  570. module_param(splashval, ulong, 0);
  571. MODULE_PARM_DESC(splashval, "Splash pattern: 0xFF is black, 0x00 is green");
  572. module_param(tuhold, ulong, 0);
  573. MODULE_PARM_DESC(tuhold, "Time to hold between strobing data to Arc board");
  574. module_param(irq, uint, 0);
  575. MODULE_PARM_DESC(irq, "IRQ for the Arc board");
  576. module_init(arcfb_init);
  577. module_exit(arcfb_exit);
  578. MODULE_DESCRIPTION("fbdev driver for Arc monochrome LCD board");
  579. MODULE_AUTHOR("Jaya Kumar");
  580. MODULE_LICENSE("GPL");