X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=arch%2Fmips%2Fpci%2Fops-au1000.c;h=c1c91ca0f9c207be4ee450b041ca4d9c9477d550;hb=6a77f38946aaee1cd85eeec6cf4229b204c15071;hp=b921cc6b306d628e56113b02903c9e00d3d71e83;hpb=87fc8d1bb10cd459024a742c6a10961fefcef18f;p=linux-2.6.git diff --git a/arch/mips/pci/ops-au1000.c b/arch/mips/pci/ops-au1000.c index b921cc6b3..c1c91ca0f 100644 --- a/arch/mips/pci/ops-au1000.c +++ b/arch/mips/pci/ops-au1000.c @@ -288,10 +288,18 @@ static int config_read(struct pci_bus *bus, unsigned int devfn, int where, int size, u32 * val) { switch (size) { - case 1: - return read_config_byte(bus, devfn, where, (u8 *) val); - case 2: - return read_config_word(bus, devfn, where, (u16 *) val); + case 1: { + u8 _val; + int rc = read_config_byte(bus, devfn, where, &_val); + *val = _val; + return rc; + } + case 2: { + u16 _val; + int rc = read_config_word(bus, devfn, where, &_val); + *val = _val; + return rc; + } default: return read_config_dword(bus, devfn, where, val); }