creates race with eventual xfer resubmission - the c_intr()
method does all the necessary handling, including re-scheduling of the
timeout handler if appropriate
also make sure to clear ATACH_IRQ_WAIT before calling c_intr(), same
as real interrupt does; this is important so that eventual spurious timeout
would not interfere with xfer handling in the atabus thread
fixes another race in the atabus thread found by KASAN, reported by Paul Ripke
processing xfer which is not quite setup
in wdcintr() actually write the error message on invocation when
not waiting for IRQ even without ATADEBUG option, as usually that
is a driver bug; might revisit this if this ends up too noisy for
PCI-IDE which seems to ignore WDCTL_IDS and hence trigger irq even
for polled commands
and successful, particularly after PIO write is finished
fixes crashes in case the setup is so slow that timeout is triggered
e.g. while still waiting in wdc_wait_for_unbusy() or shortly after, without
drive actually having chance to complete the I/O, as seen in some
configuration under QEMU by Paul Ripke
Add a quirk so that the bus front end can specify 1-bit only mode.
Remove unused isa includes.
Change the error returned for unsupported opcodes to ENOTSUP, so that
we can pass this back to sdmmc_mem, where it's handled since r1.72 of
src/sys/dev/sdmmc/sdmmc_mem.c
- Make the early i8254-based calculation of frequency a bit more accurate.
- Keep track of how far the HPET & TSC advance between HPET attach and
secondary CPU boot, and use to compute an accurate value before attaching
the timecounter. Initial idea from joerg@.
- When determining skew and drift between CPUs, make each measurement 1000
times and pick the lowest observed value. Increase the error threshold to
1000 clock cycles.
- Use the frequency computed on the boot CPU for secondary CPUs too.
- Remove cpu_counter_serializing().
8bpp Xorg wsfb server and mlterm-wscons (formerly mlterm-fb) work.
No particular comment on port-hp300@ and port-hppa@:
https://mail-index.netbsd.org/port-hp300/2020/05/02/msg000170.html
Special thanks to Miod Vallat, for his advice about HP-UX implementation
and binutils patches to disassemble old HP-UX a.out-hp300hpux binaries
(and also contributing his 425e back in 2014).
http://mail-index.netbsd.org/source-changes/2020/04/16/msg116278.html
The reasoning turned out to be wrong; __KERNEL_RCSID() in header files
does *not* overwrite RCSID in main source files. The real problem is that
it inserts its RCSID into *every* object files. However, it can be still
useful even if heavily duplicated.
overwriting RCSID in main source files.
XXX
The first argument of __KERNEL_RCSID() is neglected for ELF. If we wish
to have RCSID of header files in kernel binary, we need something like
__FBSDID() macro in FreeBSD.
driver ata_bio hooks read parts of the xfer after ata_exec_xfer()
call in order to determine return value, change so that the hook
doesn't return any value - callers do not care already,
as all I/O requests are asynchronous
this problem was uncovered by recent change for wd(4) to not hold
wd mutex during ata_bio call, the interrupt for the xfer might
thus actually fire immediately
adjust also ata_exec_command driver hooks similarily - remove all
completion and waiting logic from drivers, upper layer ata code
using AT_WAIT/AT_POLL changed to call ata_wait_cmd() itself
PR kern/55169 by Nick Hudson
and pool_prime() (and their pool_cache_* counterparts):
- the pool_set*wat() APIs are supposed to specify thresholds for the count of
free items in the pool before pool pages are automatically allocated or freed
during pool_get() / pool_put(), whereas pool_sethardlimit() and pool_prime()
are supposed to specify minimum and maximum numbers of total items
in the pool (both free and allocated). these were somewhat conflated
in the existing code, so separate them as they were intended.
- change pool_prime() to take an absolute number of items to preallocate
rather than an increment over whatever was done before, and wait for
any memory allocations to succeed. since pool_prime() can no longer fail
after this, change its return value to void and adjust all callers.
- pool_setlowat() is documented as not immediately attempting to allocate
any memory, but it was changed some time ago to immediately try to allocate
up to the lowat level, so just fix the manpage to describe the current
behaviour.
- add a pool_cache_prime() to complete the API set.
thread sleeps in wdcwait() - check current lwp rather than relying
on global ATACH_TH_RUN channel flag
should fix the hang part of the problem reported in
http://mail-index.netbsd.org/netbsd-users/2020/03/12/msg024249.html
thanks to Paul Ripke for providing extensive debugging info
core driver that understand how to find model-specific files before the
generic files. This greatly simplifies the firmware loading procedure
in each of the bus front ends. Adding additional firmware file types
(such as CLM files) much simpler.
- Make firmware image selection table-driven rather than a set of switch()
and if() statements.
- Add several additional firmware image entries.