Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/external/bsd/drm2/include/linux Fix shifts & masks in Li...
details: https://anonhg.NetBSD.org/src/rev/2be7b540dfa1
branches: trunk
changeset: 331537:2be7b540dfa1
user: riastradh <riastradh%NetBSD.org@localhost>
date: Wed Aug 13 20:56:21 2014 +0000
description:
Fix shifts & masks in Linux pci_read_config_{word,byte}.
diffstat:
sys/external/bsd/drm2/include/linux/pci.h | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r d109cbe6861e -r 2be7b540dfa1 sys/external/bsd/drm2/include/linux/pci.h
--- a/sys/external/bsd/drm2/include/linux/pci.h Wed Aug 13 20:52:05 2014 +0000
+++ b/sys/external/bsd/drm2/include/linux/pci.h Wed Aug 13 20:56:21 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pci.h,v 1.7 2014/08/06 13:52:06 riastradh Exp $ */
+/* $NetBSD: pci.h,v 1.8 2014/08/13 20:56:21 riastradh Exp $ */
/*-
* Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -200,7 +200,7 @@
{
KASSERT(!ISSET(reg, 1));
*valuep = pci_conf_read(pdev->pd_pa.pa_pc, pdev->pd_pa.pa_tag,
- (reg &~ 3)) >> (8 * (reg & 3));
+ (reg &~ 2)) >> (8 * (reg & 2));
return 0;
}
@@ -208,7 +208,7 @@
pci_read_config_byte(struct pci_dev *pdev, int reg, uint8_t *valuep)
{
*valuep = pci_conf_read(pdev->pd_pa.pa_pc, pdev->pd_pa.pa_tag,
- (reg &~ 1)) >> (8 * (reg & 1));
+ (reg &~ 3)) >> (8 * (reg & 3));
return 0;
}
Home |
Main Index |
Thread Index |
Old Index