History log of /netbsd/sys/arch/arc/jazz/fd.c (Results 1 – 25 of 51)
Revision Date Author Comments
# beecddb6 07-Aug-2021 thorpej <thorpej@NetBSD.org>

Merge thorpej-cfargs2.


# 3bee0c11 24-Apr-2021 thorpej <thorpej@NetBSD.org>

Merge thorpej-cfargs branch:

Simplify and make extensible the config_search() / config_found() /
config_attach() interfaces: rather than having different variants for
which arguments you want pass a

Merge thorpej-cfargs branch:

Simplify and make extensible the config_search() / config_found() /
config_attach() interfaces: rather than having different variants for
which arguments you want pass along, just have a single call that
takes a variadic list of tag-value arguments.

Adjust all call sites:
- Simplify wherever possible; don't pass along arguments that aren't
actually needed.
- Don't be explicit about what interface attribute is attaching if
the device only has one. (More simplification.)
- Add a config_probe() function to be used in indirect configuiration
situations, making is visibly easier to see when indirect config is
in play, and allowing for future change in semantics. (As of now,
this is just a wrapper around config_match(), but that is an
implementation detail.)

Remove unnecessary or redundant interface attributes where they're not
needed.

There are currently 5 "cfargs" defined:
- CFARG_SUBMATCH (submatch function for direct config)
- CFARG_SEARCH (search function for indirect config)
- CFARG_IATTR (interface attribte)
- CFARG_LOCATORS (locators array)
- CFARG_DEVHANDLE (devhandle_t - wraps OFW, ACPI, etc. handles)

...and a sentinel value CFARG_EOL.

Add some extra sanity checking to ensure that interface attributes
aren't ambiguous.

Use CFARG_DEVHANDLE in MI FDT, OFW, and ACPI code, and macppc and shark
ports to associate those device handles with device_t instance. This
will trickle trough to more places over time (need back-end for pre-OFW
Sun OBP; any others?).

show more ...


# 56b14b1a 08-Feb-2019 mrg <mrg@NetBSD.org>

make *fd*.c's fd_dev_to_type() always a static inline. some
have it as a const, and have code to copy the defaults to
modify them before using them, but that probably requires a
real test to feel co

make *fd*.c's fd_dev_to_type() always a static inline. some
have it as a const, and have code to copy the defaults to
modify them before using them, but that probably requires a
real test to feel confident in changing.

show more ...


# a8a5c538 03-Sep-2018 riastradh <riastradh@NetBSD.org>

Rename min/max -> uimin/uimax for better honesty.

These functions are defined on unsigned int. The generic name
min/max should not silently truncate to 32 bits on 64-bit systems.
This is purely a n

Rename min/max -> uimin/uimax for better honesty.

These functions are defined on unsigned int. The generic name
min/max should not silently truncate to 32 bits on 64-bit systems.
This is purely a name change -- no functional change intended.

HOWEVER! Some subsystems have

#define min(a, b) ((a) < (b) ? (a) : (b))
#define max(a, b) ((a) > (b) ? (a) : (b))

even though our standard name for that is MIN/MAX. Although these
may invite multiple evaluation bugs, these do _not_ cause integer
truncation.

To avoid `fixing' these cases, I first changed the name in libkern,
and then compile-tested every file where min/max occurred in order to
confirm that it failed -- and thus confirm that nothing shadowed
min/max -- before changing it.

I have left a handful of bootloaders that are too annoying to
compile-test, and some dead code:

cobalt ews4800mips hp300 hppa ia64 luna68k vax
acorn32/if_ie.c (not included in any kernels)
macppc/if_gm.c (superseded by gem(4))

It should be easy to fix the fallout once identified -- this way of
doing things fails safe, and the goal here, after all, is to _avoid_
silent integer truncations, not introduce them.

Maybe one day we can reintroduce min/max as type-generic things that
never silently truncate. But we should avoid doing that for a while,
so that existing code has a chance to be detected by the compiler for
conversion to uimin/uimax without changing the semantics until we can
properly audit it all. (Who knows, maybe in some cases integer
truncation is actually intended!)

show more ...


# 8fbc729d 26-Apr-2015 mlelstv <mlelstv@NetBSD.org>

Use C99-style initializers for struct dkdriver.


# 6e87faa0 02-Jan-2015 christos <christos@NetBSD.org>

We have three sets of DTYPE_ constants in the kernel:
altq Drop Type
disklabel Disk Type
file Descriptor Type
(not to mention constants that contain the string DTYPE).
Let's make them two, b

We have three sets of DTYPE_ constants in the kernel:
altq Drop Type
disklabel Disk Type
file Descriptor Type
(not to mention constants that contain the string DTYPE).
Let's make them two, by changing the disklabel one to be DisK TYPE since the
other disklabel constants seem to do that. Not many userland programs use
these constants (and the ones that they do are mostly in ifdefs). They will
be fixed shortly.

show more ...


# 1a918832 25-Jul-2014 dholland <dholland@NetBSD.org>

Add d_discard to all struct cdevsw instances I could find.

All have been set to "nodiscard"; some should get a real implementation.


# da8feef9 25-Jul-2014 dholland <dholland@NetBSD.org>

Add d_discard to all struct bdevsw instances I could find.

I've set them all to nodiscard. Some of them (wd, dk, vnd, ld,
raidframe, maybe cgd) should be implemented for real.


# 76258fa0 16-Mar-2014 dholland <dholland@NetBSD.org>

Change (mostly mechanically) every cdevsw/bdevsw I can find to use
designated initializers.

I have not built every extant kernel so I have probably broken at
least one build; however I've also found

Change (mostly mechanically) every cdevsw/bdevsw I can find to use
designated initializers.

I have not built every extant kernel so I have probably broken at
least one build; however I've also found and fixed some wrong
cdevsw/bdevsw entries so even if so I think we come out ahead.

show more ...


# 984edd6e 16-Dec-2013 mrg <mrg@NetBSD.org>

- remove unused variables
- use (void) when we don't care about the return value
- move variables inside their usage #if


# fe6db6ff 01-Jul-2011 dyoung <dyoung@NetBSD.org>

#include <sys/bus.h> instead of <machine/bus.h>.


# 4ee6b340 27-Sep-2009 tsutsui <tsutsui@NetBSD.org>

Replace shutdownhook_establish(9) with pmf_device_register1(9).
Tested on JC94.


# 70de9736 13-Jan-2009 yamt <yamt@NetBSD.org>

g/c BUFQ_FOO() macros and use bufq_foo() directly.


# 9a5d3f28 16-Dec-2008 christos <christos@NetBSD.org>

replace bitmask_snprintf(9) with snprintb(3)


# 0f31d9de 05-Jul-2008 tsutsui <tsutsui@NetBSD.org>

Split device_t/softc with misc related changes.


# 5b30cb96 08-Jun-2008 tsutsui <tsutsui@NetBSD.org>

Use device_lookup_private() to get softc.


# ce099b40 28-Apr-2008 martin <martin@NetBSD.org>

Remove clause 3 and 4 from TNF licenses


# d974db0a 17-Oct-2007 garbled <garbled@NetBSD.org>

Merge the ppcoea-renovation branch to HEAD.

This branch was a major cleanup and rototill of many of the various OEA
cpu based PPC ports that focused on sharing as much code as possible
between the v

Merge the ppcoea-renovation branch to HEAD.

This branch was a major cleanup and rototill of many of the various OEA
cpu based PPC ports that focused on sharing as much code as possible
between the various ports to eliminate near-identical copies of files in
every tree. Additionally there is a new PIC system that unifies the
interface to interrupt code for all different OEA ppc arches. The work
for this branch was done by a variety of people, too long to list here.

TODO:
bebox still needs work to complete the transition to -renovation.
ofppc still needs a bunch of work, which I will be looking at.
ev64260 still needs to be renovated
amigappc was not attempted.

NOTES:
pmppc was removed as an arch, and moved to a evbppc target.

show more ...


# 2af68666 08-Oct-2007 ad <ad@NetBSD.org>

Merge disk init changes from the vmlocking branch. These seperate init /
destroy of 'struct disk' from attach / detach.


# e448d821 30-Jul-2007 he <he@NetBSD.org>

Change one overlooked label reference from "bad" to "done".


# 66fefd11 29-Jul-2007 ad <ad@NetBSD.org>

It's not a good idea for device drivers to modify b_flags, as they don't
need to understand the locking around that field. Instead of setting
B_ERROR, set b_error instead. b_error is 'owned' by whoev

It's not a good idea for device drivers to modify b_flags, as they don't
need to understand the locking around that field. Instead of setting
B_ERROR, set b_error instead. b_error is 'owned' by whoever completes
the I/O request.

show more ...


# 88ab7da9 09-Jul-2007 ad <ad@NetBSD.org>

Merge some of the less invasive changes from the vmlocking branch:

- kthread, callout, devsw API changes
- select()/poll() improvements
- miscellaneous MT safety improvements


# 582dc914 06-Mar-2007 he <he@NetBSD.org>

More fixes after the caddr_t removal.
Mostly cast to char* for pointer arithmetic,
but also one missing indirection, and one "void *v, x;" fix.


# 53524e44 04-Mar-2007 christos <christos@NetBSD.org>

Kill caddr_t; there will be some MI fallout, but it will be fixed shortly.


# c234c43a 15-Apr-2006 tsutsui <tsutsui@NetBSD.org>

Include "ioconf.h" rather than declare struct cfdriver foo_cd in each file.


123