| History log of /src/sys/arch/mips/ingenic/jziic.c |
| Revision | | Date | Author | Comments |
| 1.10 |
| 15-Sep-2025 |
thorpej | Encapsulate what's needed to attach an I2C bus into a iicbus_attach() inline.
|
| 1.9 |
| 07-Aug-2021 |
thorpej | Merge thorpej-cfargs2.
|
| 1.8 |
| 24-Apr-2021 |
thorpej | branches: 1.8.8; 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?).
|
| 1.7 |
| 23-Dec-2019 |
thorpej | branches: 1.7.10; No need to check cold ourselves; iic_exec() does it for us.
|
| 1.6 |
| 22-Dec-2019 |
thorpej | Cleanup i2c bus acquire / release, centralizing all of the logic into iic_acquire_bus() / iic_release_bus(). "acquire" and "release" hooks no longer need to be provided by back-end controller drivers (only if they need special handling, e.g. powering on the i2c controller). This results in the removal of a bunch of rendundant code from each back-end controller driver.
Assert that we are not in hard interrupt context in iic_acquire_bus(), iic_exec(), and iic_release_bus().
|
| 1.5 |
| 03-Sep-2018 |
riastradh | 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!)
|
| 1.4 |
| 19-May-2017 |
skrll | branches: 1.4.8; 1.4.10; 1.4.12; Trailing whitespace
|
| 1.3 |
| 14-Dec-2015 |
macallan | zero out struct i2cbus_attach_args before messing with it
|
| 1.2 |
| 21-Apr-2015 |
macallan | support interrupt-driven transfers
|
| 1.1 |
| 04-Apr-2015 |
macallan | branches: 1.1.2; preliminary driver for JZ4780's on-chip SMBus controllers needs more work but it's good enough for talking to an RTC
|
| 1.1.2.4 |
| 27-Dec-2015 |
skrll | Sync with HEAD (as of 26th Dec)
|
| 1.1.2.3 |
| 06-Jun-2015 |
skrll | Sync with HEAD
|
| 1.1.2.2 |
| 06-Apr-2015 |
skrll | Sync with HEAD
|
| 1.1.2.1 |
| 04-Apr-2015 |
skrll | file jziic.c was added on branch nick-nhusb on 2015-04-06 15:17:59 +0000
|
| 1.4.12.2 |
| 08-Apr-2020 |
martin | Merge changes from current as of 20200406
|
| 1.4.12.1 |
| 10-Jun-2019 |
christos | Sync with HEAD
|
| 1.4.10.1 |
| 06-Sep-2018 |
pgoyette | Sync with HEAD
Resolve a couple of conflicts (result of the uimin/uimax changes)
|
| 1.4.8.2 |
| 03-Dec-2017 |
jdolecek | update from HEAD
|
| 1.4.8.1 |
| 19-May-2017 |
jdolecek | file jziic.c was added on branch tls-maxphys on 2017-12-03 11:36:28 +0000
|
| 1.7.10.1 |
| 23-Mar-2021 |
thorpej | Convert config_found_ia() call sites where the device only carries a single interface attribute to bare config_found() calls.
|
| 1.8.8.1 |
| 04-Aug-2021 |
thorpej | Adapt to CFARGS().
|