- added udelay() in epat wake up function to get some 2000P correctly

detected on fast hardware.
DEVEL_2_0_BRANCH-1
Stéphane Voltz 2002-01-24 05:56:13 +00:00
rodzic e118d4e33b
commit 4548a075aa
1 zmienionych plików z 33 dodań i 12 usunięć

Wyświetl plik

@ -2550,18 +2550,29 @@ RingScanner (void)
/* send ring string */
Outb (DATA, 0x22);
usleep (10000);
Outb (DATA, 0x22);
usleep (10000);
Outb (DATA, 0xAA);
usleep (10000);
Outb (DATA, 0xAA);
usleep (10000);
Outb (DATA, 0x55);
usleep (10000);
Outb (DATA, 0x55);
usleep (10000);
Outb (DATA, 0x00);
usleep (10000);
Outb (DATA, 0x00);
usleep (10000);
Outb (DATA, 0xFF);
usleep (10000);
Outb (DATA, 0xFF);
usleep (10000);
/* OK ? */
status = Inb (STATUS);
usleep (10000);
if ((status & 0xB8) != 0xB8)
{
DBG (1, "status %d doesn't match! %s:%d\n", status, __FILE__, __LINE__);
@ -2572,8 +2583,11 @@ RingScanner (void)
if (ret)
{
Outb (DATA, 0x87);
usleep (10000);
Outb (DATA, 0x87);
usleep (10000);
status = Inb (STATUS);
usleep (10000);
if ((status & 0xB8) != 0x18)
{
DBG (1, "status %d doesn't match! %s:%d\n", status, __FILE__,
@ -2586,7 +2600,9 @@ RingScanner (void)
if (ret)
{
Outb (DATA, 0x78);
usleep (10000);
Outb (DATA, 0x78);
usleep (10000);
status = Inb (STATUS);
if ((status & 0x30) != 0x30)
{
@ -2600,9 +2616,13 @@ RingScanner (void)
if (ret)
{
Outb (DATA, 0x08);
usleep (10000);
Outb (DATA, 0x08);
usleep (10000);
Outb (DATA, 0xFF);
usleep (10000);
Outb (DATA, 0xFF);
usleep (10000);
}
/* restore state */
@ -6214,7 +6234,8 @@ DumpRGB (int width, int height, unsigned char *data, char *name)
fclose (fic);
}
static int EvalGain(int sum,int count)
static int
EvalGain (int sum, int count)
{
int gn;