Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 248116
b: refs/heads/master
c: 6ec5ff4
h: refs/heads/master
v: v3
  • Loading branch information
Gustavo F. Padovan authored and Ingo Molnar committed May 21, 2011
1 parent 908cffc commit 1a1e5df
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 17 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: 1d487624fcc17a40aa67acaa9e8f3815fb7cd0f0
refs/heads/master: 6ec5ff4bc3a90b7716eadc4c8a686e904131f03a
5 changes: 1 addition & 4 deletions trunk/arch/x86/kernel/amd_iommu.c
Original file line number Diff line number Diff line change
Expand Up @@ -1538,13 +1538,11 @@ static void do_detach(struct device *dev)
{
struct iommu_dev_data *dev_data;
struct amd_iommu *iommu;
struct pci_dev *pdev;
u16 devid;

devid = get_device_id(dev);
iommu = amd_iommu_rlookup_table[devid];
dev_data = get_dev_data(dev);
pdev = to_pci_dev(dev);

/* decrease reference counters */
dev_data->domain->dev_iommu[iommu->index] -= 1;
Expand Down Expand Up @@ -1703,10 +1701,9 @@ static struct protection_domain *domain_for_device(struct device *dev)
struct protection_domain *dom;
struct iommu_dev_data *dev_data, *alias_data;
unsigned long flags;
u16 devid, alias;
u16 devid;

devid = get_device_id(dev);
alias = amd_iommu_alias_table[devid];
dev_data = get_dev_data(dev);
alias_data = get_dev_data(dev_data->alias);
if (!alias_data)
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/x86/kernel/test_nx.c
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ static int test_NX(void)
}

#endif
return 0;
return ret;
}

static void test_exit(void)
Expand Down
14 changes: 3 additions & 11 deletions trunk/arch/x86/mm/pf_in.c
Original file line number Diff line number Diff line change
Expand Up @@ -414,22 +414,17 @@ unsigned long get_ins_reg_val(unsigned long ins_addr, struct pt_regs *regs)
unsigned char *p;
struct prefix_bits prf;
int i;
unsigned long rv;

p = (unsigned char *)ins_addr;
p += skip_prefix(p, &prf);
p += get_opcode(p, &opcode);
for (i = 0; i < ARRAY_SIZE(reg_rop); i++)
if (reg_rop[i] == opcode) {
rv = REG_READ;
if (reg_rop[i] == opcode)
goto do_work;
}

for (i = 0; i < ARRAY_SIZE(reg_wop); i++)
if (reg_wop[i] == opcode) {
rv = REG_WRITE;
if (reg_wop[i] == opcode)
goto do_work;
}

printk(KERN_ERR "mmiotrace: Not a register instruction, opcode "
"0x%02x\n", opcode);
Expand Down Expand Up @@ -474,16 +469,13 @@ unsigned long get_ins_imm_val(unsigned long ins_addr)
unsigned char *p;
struct prefix_bits prf;
int i;
unsigned long rv;

p = (unsigned char *)ins_addr;
p += skip_prefix(p, &prf);
p += get_opcode(p, &opcode);
for (i = 0; i < ARRAY_SIZE(imm_wop); i++)
if (imm_wop[i] == opcode) {
rv = IMM_WRITE;
if (imm_wop[i] == opcode)
goto do_work;
}

printk(KERN_ERR "mmiotrace: Not an immediate instruction, opcode "
"0x%02x\n", opcode);
Expand Down

0 comments on commit 1a1e5df

Please sign in to comment.