Commit 3f4d4f4e authored by Russell King's avatar Russell King

Miscellaneous build/bug fixes.

parent 4dfff8c1
......@@ -620,15 +620,9 @@ asmlinkage int sys_ptrace(long request, long pid, long addr, long data)
ret = ptrace_attach(child);
goto out_tsk;
}
ret = -ESRCH;
if (!(child->ptrace & PT_PTRACED))
goto out_tsk;
if (child->state != TASK_STOPPED && request != PTRACE_KILL)
goto out_tsk;
if (child->p_pptr != current)
goto out_tsk;
ret = do_ptrace(request, child, addr, data);
ret = ptrace_check_attach(child, request == PTRACE_KILL);
if (ret == 0)
ret = do_ptrace(request, child, addr, data);
out_tsk:
put_task_struct(child);
......
......@@ -15,11 +15,11 @@
.text
.align 5
ENTRY(memchr)
1: ldrb r3, [r0], #1
1: subs r2, r2, #1
bmi 2f
ldrb r3, [r0], #1
teq r3, r1
beq 2f
subs r2, r2, #1
bpl 1b
bne 1b
sub r0, r0, #1
2: movne r0, #0
subeq r0, r0, #1
RETINSTR(mov,pc,lr)
......@@ -162,3 +162,47 @@ void __init sa1100_map_io(void)
{
iotable_init(standard_io_desc);
}
/*
* Disable the memory bus request/grant signals on the SA1110 to
* ensure that we don't receive spurious memory requests. We set
* the MBGNT signal false to ensure the SA1111 doesn't own the
* SDRAM bus.
*/
void __init sa1110_mb_disable(void)
{
unsigned long flags;
local_irq_save(flags);
PGSR &= ~GPIO_MBGNT;
GPCR = GPIO_MBGNT;
GPDR = (GPDR & ~GPIO_MBREQ) | GPIO_MBGNT;
GAFR &= ~(GPIO_MBGNT | GPIO_MBREQ);
local_irq_restore(flags);
}
/*
* If the system is going to use the SA-1111 DMA engines, set up
* the memory bus request/grant pins.
*/
void __init sa1110_mb_enable(void)
{
unsigned long flags;
local_irq_save(flags);
PGSR &= ~GPIO_MBGNT;
GPCR = GPIO_MBGNT;
GPDR = (GPDR & ~GPIO_MBREQ) | GPIO_MBGNT;
GAFR |= (GPIO_MBGNT | GPIO_MBREQ);
TUCR |= TUCR_MR;
local_irq_restore(flags);
}
EXPORT_SYMBOL(sa1111_wake);
EXPORT_SYMBOL(sa1111_doze);
......@@ -15,3 +15,5 @@ extern void __init sa1100_init_irq(void);
extern void (*sa1100fb_backlight_power)(int on);
extern void (*sa1100fb_lcd_power)(int on);
extern void sa1110_mb_enable(void);
extern void sa1110_mb_disable(void);
......@@ -367,50 +367,6 @@ void sa1111_configure_smc(int sdram, unsigned int drac, unsigned int cas_latency
SBI_SMCR = smcr;
}
/*
* Disable the memory bus request/grant signals on the SA1110 to
* ensure that we don't receive spurious memory requests. We set
* the MBGNT signal false to ensure the SA1111 doesn't own the
* SDRAM bus.
*/
void __init sa1110_mb_disable(void)
{
unsigned long flags;
local_irq_save(flags);
PGSR &= ~GPIO_MBGNT;
GPCR = GPIO_MBGNT;
GPDR = (GPDR & ~GPIO_MBREQ) | GPIO_MBGNT;
GAFR &= ~(GPIO_MBGNT | GPIO_MBREQ);
local_irq_restore(flags);
}
/*
* If the system is going to use the SA-1111 DMA engines, set up
* the memory bus request/grant pins.
*/
void __init sa1110_mb_enable(void)
{
unsigned long flags;
local_irq_save(flags);
PGSR &= ~GPIO_MBGNT;
GPCR = GPIO_MBGNT;
GPDR = (GPDR & ~GPIO_MBREQ) | GPIO_MBGNT;
GAFR |= (GPIO_MBGNT | GPIO_MBREQ);
TUCR |= TUCR_MR;
local_irq_restore(flags);
}
EXPORT_SYMBOL(sa1111_wake);
EXPORT_SYMBOL(sa1111_doze);
/* According to the "Intel StrongARM SA-1111 Microprocessor Companion
* Chip Specification Update" (June 2000), erratum #7, there is a
* significant bug in Serial Audio Controller DMA. If the SAC is
......
......@@ -2,12 +2,6 @@
* linux/arch/arm/mach-sa1100/sa1111.h
*/
/*
* These two don't really belong in here.
*/
extern void sa1110_mb_enable(void);
extern void sa1110_mb_disable(void);
/*
* Probe for a SA1111 chip.
*/
......@@ -27,8 +21,4 @@ extern void sa1111_doze(void);
* Configure the SA1111 shared memory controller.
*/
extern void sa1111_configure_smc(int sdram, unsigned int drac, unsigned int cas_latency);
extern void sa1111_init_irq(int irq_nr);
extern void sa1111_IRQ_demux(int irq, void *dev_id, struct pt_regs *regs);
......@@ -6,7 +6,7 @@
# To add an entry into this database, please see Documentation/arm/README,
# or contact rmk@arm.linux.org.uk
#
# Last update: Sat Mar 16 10:55:44 2002
# Last update: Sun Mar 24 11:48:10 2002
#
# machine_is_xxx CONFIG_xxxx MACH_TYPE_xxx number
#
......@@ -178,3 +178,4 @@ sam2400 ARCH_SAM2400 SAM2400 166
jornada56x ARCH_JORNADA56X JORNADA56X 167
active SA1100_ACTIVE ACTIVE 168
iq80321 ARCH_IQ80321 IQ80321 169
wid SA1100_WID WID 170
......@@ -441,7 +441,7 @@ icside_dmaproc(ide_dma_action_t func, ide_drive_t *drive)
: DMA_MODE_WRITE);
drive->waiting_for_dma = 1;
if (drive->media != ide_disk)
if (drive->type != ATA_DISK)
return 0;
ide_set_handler(drive, &icside_dmaintr, WAIT_CMD, NULL);
......
......@@ -1402,6 +1402,7 @@ cyberpro_alloc_fb_info(unsigned int id, char *name)
cfb->fb.updatevar = cyber2000fb_updatevar;
cfb->fb.blank = cyber2000fb_blank;
cfb->fb.flags = FBINFO_FLAG_DEFAULT;
cfb->fb.node = NODEV;
cfb->fb.disp = (struct display *)(cfb + 1);
cfb->fb.pseudo_palette = (void *)(cfb->fb.disp + 1);
......@@ -1819,7 +1820,7 @@ static struct pci_driver cyberpro_driver = {
*/
int __init cyber2000fb_init(void)
{
int ret = -1, err = 0;
int ret = -1, err = -ENODEV;
#ifdef CONFIG_ARCH_SHARK
err = cyberpro_vl_probe();
if (!err) {
......@@ -1827,19 +1828,16 @@ int __init cyber2000fb_init(void)
MOD_INC_USE_COUNT;
}
#endif
#ifdef CONFIG_PCI
err = pci_module_init(&cyberpro_driver);
if (!err)
ret = err;
#endif
return ret ? err : 0;
}
static void __exit cyberpro_exit(void)
{
#ifdef CONFIG_PCI
pci_unregister_driver(&cyberpro_driver);
#endif
}
#ifdef MODULE
......
......@@ -30,4 +30,6 @@ extern void free_pgd_slow(pgd_t *pgd);
#define pgd_alloc(mm) get_pgd_slow(mm)
#define pgd_free(pgd) free_pgd_slow(pgd)
#define check_pgt_cache() do { } while (0)
#endif
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment