Commit 3656b384 authored by David S. Miller's avatar David S. Miller

Merge davem@nuts.ninka.net:/disk1/davem/BK/sparc-2.5

into kernel.bkbits.net:/home/davem/sparc-2.5
parents dd6c83a6 4154cebf
......@@ -190,16 +190,27 @@ void * __ioremap(unsigned long phys_addr, unsigned long size, unsigned long flag
void *ioremap_nocache (unsigned long phys_addr, unsigned long size)
{
unsigned long last_addr;
void *p = __ioremap(phys_addr, size, _PAGE_PCD);
if (!p)
return p;
if (phys_addr + size < virt_to_phys(high_memory)) {
/* Guaranteed to be > phys_addr, as per __ioremap() */
last_addr = phys_addr + size - 1;
if (last_addr < virt_to_phys(high_memory)) {
struct page *ppage = virt_to_page(__va(phys_addr));
unsigned long npages = (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
unsigned long npages;
phys_addr &= PAGE_MASK;
/* This might overflow and become zero.. */
last_addr = PAGE_ALIGN(last_addr);
BUG_ON(phys_addr+size > (unsigned long)high_memory);
BUG_ON(phys_addr + size < phys_addr);
/* .. but that's ok, because modulo-2**n arithmetic will make
* the page-aligned "last - first" come out right.
*/
npages = (last_addr - phys_addr) >> PAGE_SHIFT;
if (change_page_attr(ppage, npages, PAGE_KERNEL_NOCACHE) < 0) {
iounmap(p);
......
......@@ -77,7 +77,7 @@ wrap_mmu_context (struct mm_struct *mm)
{
int cpu = get_cpu(); /* prevent preemption/migration */
for (i = 0; i < NR_CPUS; ++i)
if (i != cpu)
if (cpu_online(i) && (i != cpu))
per_cpu(ia64_need_tlb_flush, i) = 1;
put_cpu();
}
......
......@@ -279,8 +279,7 @@ sn_pci_map_sg(struct pci_dev *hwdev, struct scatterlist *sg, int nents, int dire
* scatterlist.
*/
for (i = 0; i < nents; i++, sg++) {
phys_addr = __pa(sg->dma_address ? sg->dma_address :
(unsigned long)page_address(sg->page) + sg->offset);
phys_addr = __pa((unsigned long)page_address(sg->page) + sg->offset);
/*
* Handle the most common case: 64 bit cards. This
......
......@@ -780,6 +780,11 @@ static char *rq_flags[] = {
"REQ_PM_SUSPEND",
"REQ_PM_RESUME",
"REQ_PM_SHUTDOWN",
"REQ_IDETAPE_PC1",
"REQ_IDETAPE_PC2",
"REQ_IDETAPE_READ",
"REQ_IDETAPE_WRITE",
"REQ_IDETAPE_READ_BUFFER",
};
void blk_dump_rq_flags(struct request *rq, char *msg)
......
This diff is collapsed.
......@@ -422,7 +422,7 @@ static __init int trif_probe(int unit)
extern int loopback_init(void);
/* Statically configured drivers -- order matters here. */
void __init probe_old_netdevs(void)
static int __init net_olddevs_init(void)
{
int num;
......@@ -450,8 +450,12 @@ void __init probe_old_netdevs(void)
#ifdef CONFIG_LTPC
ltpc_probe();
#endif
return 0;
}
device_initcall(net_olddevs_init);
/*
* The @dev_base list is protected by @dev_base_lock and the rtln
* semaphore.
......
......@@ -193,6 +193,11 @@ enum rq_flag_bits {
__REQ_PM_SUSPEND, /* suspend request */
__REQ_PM_RESUME, /* resume request */
__REQ_PM_SHUTDOWN, /* shutdown request */
__REQ_IDETAPE_PC1, /* packet command (first stage) */
__REQ_IDETAPE_PC2, /* packet command (second stage) */
__REQ_IDETAPE_READ,
__REQ_IDETAPE_WRITE,
__REQ_IDETAPE_READ_BUFFER,
__REQ_NR_BITS, /* stops here */
};
......@@ -218,6 +223,11 @@ enum rq_flag_bits {
#define REQ_PM_SUSPEND (1 << __REQ_PM_SUSPEND)
#define REQ_PM_RESUME (1 << __REQ_PM_RESUME)
#define REQ_PM_SHUTDOWN (1 << __REQ_PM_SHUTDOWN)
#define REQ_IDETAPE_PC1 (1 << __REQ_IDETAPE_PC1)
#define REQ_IDETAPE_PC2 (1 << __REQ_IDETAPE_PC2)
#define REQ_IDETAPE_READ (1 << __REQ_IDETAPE_READ)
#define REQ_IDETAPE_WRITE (1 << __REQ_IDETAPE_WRITE)
#define REQ_IDETAPE_READ_BUFFER (1 << __REQ_IDETAPE_READ_BUFFER)
/*
* State information carried for REQ_PM_SUSPEND and REQ_PM_RESUME
......
......@@ -494,7 +494,6 @@ extern struct net_device loopback_dev; /* The loopback */
extern struct net_device *dev_base; /* All devices */
extern rwlock_t dev_base_lock; /* Device list lock */
extern void probe_old_netdevs(void);
extern int netdev_boot_setup_add(char *name, struct ifmap *map);
extern int netdev_boot_setup_check(struct net_device *dev);
extern struct net_device *dev_getbyhwaddr(unsigned short type, char *hwaddr);
......
......@@ -3033,8 +3033,6 @@ static int __init net_dev_init(void)
dev_boot_phase = 0;
probe_old_netdevs();
open_softirq(NET_TX_SOFTIRQ, net_tx_action, NULL);
open_softirq(NET_RX_SOFTIRQ, net_rx_action, NULL);
......
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