Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 5756
b: refs/heads/master
c: 1b9749e
h: refs/heads/master
v: v3
  • Loading branch information
Russell King authored and Russell King committed Aug 10, 2005
1 parent 3dee03f commit 1743add
Show file tree
Hide file tree
Showing 9 changed files with 37 additions and 73 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 22d0def9d09111513f5a8d38583210620f97d710
refs/heads/master: 1b9749e7f15bf2db19f5d201f88401c7517910b7
20 changes: 7 additions & 13 deletions trunk/arch/arm/mm/proc-v6.S
Original file line number Diff line number Diff line change
Expand Up @@ -111,12 +111,6 @@ ENTRY(cpu_v6_switch_mm)
mcr p15, 0, r1, c13, c0, 1 @ set context ID
mov pc, lr

#define nG (1 << 11)
#define APX (1 << 9)
#define AP1 (1 << 5)
#define AP0 (1 << 4)
#define XN (1 << 0)

/*
* cpu_v6_set_pte(ptep, pte)
*
Expand All @@ -141,22 +135,22 @@ ENTRY(cpu_v6_set_pte)

bic r2, r1, #0x00000ff0
bic r2, r2, #0x00000003
orr r2, r2, #AP0 | 2
orr r2, r2, #PTE_EXT_AP0 | 2

tst r1, #L_PTE_WRITE
tstne r1, #L_PTE_DIRTY
orreq r2, r2, #APX
orreq r2, r2, #PTE_EXT_APX

tst r1, #L_PTE_USER
orrne r2, r2, #AP1 | nG
tstne r2, #APX
bicne r2, r2, #APX | AP0
orrne r2, r2, #PTE_EXT_AP1 | PTE_EXT_NG
tstne r2, #PTE_EXT_APX
bicne r2, r2, #PTE_EXT_APX | PTE_EXT_AP0

tst r1, #L_PTE_YOUNG
biceq r2, r2, #APX | AP1 | AP0
biceq r2, r2, #PTE_EXT_APX | PTE_EXT_AP_MASK

@ tst r1, #L_PTE_EXEC
@ orreq r2, r2, #XN
@ orreq r2, r2, #PTE_EXT_XN

tst r1, #L_PTE_PRESENT
moveq r2, #0
Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/input/gameport/ns558.c
Original file line number Diff line number Diff line change
Expand Up @@ -275,9 +275,9 @@ static int __init ns558_init(void)

static void __exit ns558_exit(void)
{
struct ns558 *ns558, *safe;
struct ns558 *ns558;

list_for_each_entry_safe(ns558, safe, &ns558_list, node) {
list_for_each_entry(ns558, &ns558_list, node) {
gameport_unregister_port(ns558->gameport);
release_region(ns558->io & ~(ns558->size - 1), ns558->size);
kfree(ns558);
Expand Down
20 changes: 16 additions & 4 deletions trunk/drivers/net/hamradio/6pack.c
Original file line number Diff line number Diff line change
Expand Up @@ -130,19 +130,20 @@ struct sixpack {

#define AX25_6PACK_HEADER_LEN 0

static void sp_start_tx_timer(struct sixpack *);
static void sixpack_decode(struct sixpack *, unsigned char[], int);
static int encode_sixpack(unsigned char *, unsigned char *, int, unsigned char);

/*
* Perform the persistence/slottime algorithm for CSMA access. If the
* perform the persistence/slottime algorithm for CSMA access. If the
* persistence check was successful, write the data to the serial driver.
* Note that in case of DAMA operation, the data is not sent here.
*/

static void sp_xmit_on_air(unsigned long channel)
{
struct sixpack *sp = (struct sixpack *) channel;
int actual, when = sp->slottime;
int actual;
static unsigned char random;

random = random * 17 + 41;
Expand All @@ -158,10 +159,20 @@ static void sp_xmit_on_air(unsigned long channel)
sp->tty->driver->write(sp->tty, &sp->led_state, 1);
sp->status2 = 0;
} else
mod_timer(&sp->tx_t, jiffies + ((when + 1) * HZ) / 100);
sp_start_tx_timer(sp);
}

/* ----> 6pack timer interrupt handler and friends. <---- */
static void sp_start_tx_timer(struct sixpack *sp)
{
int when = sp->slottime;

del_timer(&sp->tx_t);
sp->tx_t.data = (unsigned long) sp;
sp->tx_t.function = sp_xmit_on_air;
sp->tx_t.expires = jiffies + ((when + 1) * HZ) / 100;
add_timer(&sp->tx_t);
}

/* Encapsulate one AX.25 frame and stuff into a TTY queue. */
static void sp_encaps(struct sixpack *sp, unsigned char *icp, int len)
Expand Down Expand Up @@ -232,7 +243,8 @@ static void sp_encaps(struct sixpack *sp, unsigned char *icp, int len)
sp->xleft = count;
sp->xhead = sp->xbuff;
sp->status2 = count;
sp_xmit_on_air((unsigned long)sp);
if (sp->duplex == 0)
sp_start_tx_timer(sp);
}

return;
Expand Down
9 changes: 1 addition & 8 deletions trunk/drivers/scsi/dpt_i2o.c
Original file line number Diff line number Diff line change
Expand Up @@ -907,13 +907,9 @@ static int adpt_install_hba(struct scsi_host_template* sht, struct pci_dev* pDev
raptorFlag = TRUE;
}

if (pci_request_regions(pDev, "dpt_i2o")) {
PERROR("dpti: adpt_config_hba: pci request region failed\n");
return -EINVAL;
}

base_addr_virt = ioremap(base_addr0_phys,hba_map0_area_size);
if (!base_addr_virt) {
pci_release_regions(pDev);
PERROR("dpti: adpt_config_hba: io remap failed\n");
return -EINVAL;
}
Expand All @@ -923,7 +919,6 @@ static int adpt_install_hba(struct scsi_host_template* sht, struct pci_dev* pDev
if (!msg_addr_virt) {
PERROR("dpti: adpt_config_hba: io remap failed on BAR1\n");
iounmap(base_addr_virt);
pci_release_regions(pDev);
return -EINVAL;
}
} else {
Expand All @@ -937,7 +932,6 @@ static int adpt_install_hba(struct scsi_host_template* sht, struct pci_dev* pDev
iounmap(msg_addr_virt);
}
iounmap(base_addr_virt);
pci_release_regions(pDev);
return -ENOMEM;
}
memset(pHba, 0, sizeof(adpt_hba));
Expand Down Expand Up @@ -1033,7 +1027,6 @@ static void adpt_i2o_delete_hba(adpt_hba* pHba)
up(&adpt_configuration_lock);

iounmap(pHba->base_addr_virt);
pci_release_regions(pHba->pDev);
if(pHba->msg_addr_virt != pHba->base_addr_virt){
iounmap(pHba->msg_addr_virt);
}
Expand Down
16 changes: 1 addition & 15 deletions trunk/drivers/scsi/scsi_scan.c
Original file line number Diff line number Diff line change
Expand Up @@ -336,23 +336,9 @@ static struct scsi_target *scsi_alloc_target(struct device *parent,
unsigned long flags;
const int size = sizeof(struct scsi_target)
+ shost->transportt->target_size;
struct scsi_target *starget;
struct scsi_target *starget = kmalloc(size, GFP_ATOMIC);
struct scsi_target *found_target;

/*
* Obtain the real parent from the transport. The transport
* is allowed to fail (no error) if there is nothing at that
* target id.
*/
if (shost->transportt->target_parent) {
spin_lock_irqsave(shost->host_lock, flags);
parent = shost->transportt->target_parent(shost, channel, id);
spin_unlock_irqrestore(shost->host_lock, flags);
if (!parent)
return NULL;
}

starget = kmalloc(size, GFP_KERNEL);
if (!starget) {
printk(KERN_ERR "%s: allocation failure\n", __FUNCTION__);
return NULL;
Expand Down
19 changes: 0 additions & 19 deletions trunk/drivers/scsi/scsi_transport_fc.c
Original file line number Diff line number Diff line change
Expand Up @@ -1022,23 +1022,6 @@ static int fc_rport_match(struct attribute_container *cont,
return &i->rport_attr_cont.ac == cont;
}


/*
* Must be called with shost->host_lock held
*/
static struct device *fc_target_parent(struct Scsi_Host *shost,
int channel, uint id)
{
struct fc_rport *rport;

list_for_each_entry(rport, &fc_host_rports(shost), peers)
if ((rport->channel == channel) &&
(rport->scsi_target_id == id))
return &rport->dev;

return NULL;
}

struct scsi_transport_template *
fc_attach_transport(struct fc_function_template *ft)
{
Expand Down Expand Up @@ -1074,8 +1057,6 @@ fc_attach_transport(struct fc_function_template *ft)

/* Transport uses the shost workq for scsi scanning */
i->t.create_work_queue = 1;

i->t.target_parent = fc_target_parent;

/*
* Setup SCSI Target Attributes.
Expand Down
12 changes: 9 additions & 3 deletions trunk/include/asm-arm/pgtable.h
Original file line number Diff line number Diff line change
Expand Up @@ -188,12 +188,18 @@ extern void __pgd_error(const char *file, int line, unsigned long val);
/*
* - extended small page/tiny page
*/
#define PTE_EXT_XN (1 << 0) /* v6 */
#define PTE_EXT_AP_MASK (3 << 4)
#define PTE_EXT_AP0 (1 << 4)
#define PTE_EXT_AP1 (2 << 4)
#define PTE_EXT_AP_UNO_SRO (0 << 4)
#define PTE_EXT_AP_UNO_SRW (1 << 4)
#define PTE_EXT_AP_URO_SRW (2 << 4)
#define PTE_EXT_AP_URW_SRW (3 << 4)
#define PTE_EXT_AP_UNO_SRW (PTE_EXT_AP0)
#define PTE_EXT_AP_URO_SRW (PTE_EXT_AP1)
#define PTE_EXT_AP_URW_SRW (PTE_EXT_AP1|PTE_EXT_AP0)
#define PTE_EXT_TEX(x) ((x) << 6) /* v5 */
#define PTE_EXT_APX (1 << 9) /* v6 */
#define PTE_EXT_SHARED (1 << 10) /* v6 */
#define PTE_EXT_NG (1 << 11) /* v6 */

/*
* - small page
Expand Down
8 changes: 0 additions & 8 deletions trunk/include/scsi/scsi_transport.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,6 @@ struct scsi_transport_template {
struct transport_container target_attrs;
struct transport_container device_attrs;

/*
* If set, call target_parent prior to allocating a scsi_target,
* so we get the appropriate parent for the target. This function
* is required for transports like FC and iSCSI that do not put the
* scsi_target under scsi_host.
*/
struct device *(*target_parent)(struct Scsi_Host *, int, uint);

/* The size of the specific transport attribute structure (a
* space of this size will be left at the end of the
* scsi_* structure */
Expand Down

0 comments on commit 1743add

Please sign in to comment.