svn commit: r366312 - head/sys/dev/extres/syscon
Michal Meloun
mmel at FreeBSD.org
Thu Oct 1 09:50:09 UTC 2020
Author: mmel
Date: Thu Oct 1 09:50:08 2020
New Revision: 366312
URL: https://svnweb.freebsd.org/changeset/base/366312
Log:
Fix the inverted condition in mtx_asserts.
Mutex should be owned in affected functions.
Reborted by: emaste
MFC after: 4 weeks
MFC with: r366161
Modified:
head/sys/dev/extres/syscon/syscon_generic.c
Modified: head/sys/dev/extres/syscon/syscon_generic.c
==============================================================================
--- head/sys/dev/extres/syscon/syscon_generic.c Thu Oct 1 08:57:36 2020 (r366311)
+++ head/sys/dev/extres/syscon/syscon_generic.c Thu Oct 1 09:50:08 2020 (r366312)
@@ -95,7 +95,7 @@ syscon_generic_unlocked_read_4(struct syscon *syscon,
uint32_t val;
sc = device_get_softc(syscon->pdev);
- SYSCON_ASSERT_UNLOCKED(sc);
+ SYSCON_ASSERT_LOCKED(sc);
val = bus_read_4(sc->mem_res, offset);
return (val);
}
@@ -106,7 +106,7 @@ syscon_generic_unlocked_write_4(struct syscon *syscon,
struct syscon_generic_softc *sc;
sc = device_get_softc(syscon->pdev);
- SYSCON_ASSERT_UNLOCKED(sc);
+ SYSCON_ASSERT_LOCKED(sc);
bus_write_4(sc->mem_res, offset, val);
return (0);
}
@@ -119,7 +119,7 @@ syscon_generic_unlocked_modify_4(struct syscon *syscon
uint32_t val;
sc = device_get_softc(syscon->pdev);
- SYSCON_ASSERT_UNLOCKED(sc);
+ SYSCON_ASSERT_LOCKED(sc);
val = bus_read_4(sc->mem_res, offset);
val &= ~clear_bits;
val |= set_bits;
More information about the svn-src-head
mailing list