16550: Use generic console_t data structureSince now the generic console_t structure holds the UART base address aswell, let's use that generic location and drop the UART driver specificdata stru
16550: Use generic console_t data structureSince now the generic console_t structure holds the UART base address aswell, let's use that generic location and drop the UART driver specificdata structure at all.Change-Id: I5c2fe3b6a667acf80c808cfec4a64059a2c9c25fSigned-off-by: Andre Przywara <andre.przywara@arm.com>
show more ...
console: 16550: Prepare for skipping initialisationOn some platforms the UART might have already been initialised, forinstance by firmware running before TF-A or by a separate managementprocessor
console: 16550: Prepare for skipping initialisationOn some platforms the UART might have already been initialised, forinstance by firmware running before TF-A or by a separate managementprocessor. In this case it would not be need to initialise it again(doing so could create spurious characters). But more importantly thissaves us from knowing the right baudrate and the right base clock ratefor the UART. This can lead to more robust and versatile firmware builds.Allow to skip the 16550 UART initialisation and baud rate divisorprogramming, by interpreting an input clock rate of "0" to signify thiscase. This will just skip the call to console_16550_core_init, but stillwill register the console properly.Users should just pass 0 as the second parameter, the baudrate (thirdparameter) will then be ignored as well.Fix copy & paste typos in comments for the console_16550_register()function on the way.Signed-off-by: Andre Przywara <andre.przywara@arm.com>Change-Id: I9f8fca5b358f878fac0f31dc411358fd160786ee
Replace __ASSEMBLY__ with compiler-builtin __ASSEMBLER__NOTE: __ASSEMBLY__ macro is now deprecated in favor of __ASSEMBLER__.All common C compilers predefine a macro called __ASSEMBLER__ whenpre
Replace __ASSEMBLY__ with compiler-builtin __ASSEMBLER__NOTE: __ASSEMBLY__ macro is now deprecated in favor of __ASSEMBLER__.All common C compilers predefine a macro called __ASSEMBLER__ whenpreprocessing a .S file. There is no reason for TF-A to define it's own__ASSEMBLY__ macro for this purpose instead. To unify code with theexport headers (which use __ASSEMBLER__ to avoid one extra dependency),let's deprecate __ASSEMBLY__ and switch the code base over to thepredefined standard.Change-Id: Id7d0ec8cf330195da80499c68562b65cb5ab7417Signed-off-by: Julius Werner <jwerner@chromium.org>
Sanitise includes across codebaseEnforce full include path for includes. Deprecate old paths.The following folders inside include/lib have been left unchanged:- include/lib/cpus/${ARCH}- inclu
Sanitise includes across codebaseEnforce full include path for includes. Deprecate old paths.The following folders inside include/lib have been left unchanged:- include/lib/cpus/${ARCH}- include/lib/el3_runtime/${ARCH}The reason for this change is that having a global namespace forincludes isn't a good idea. It defeats one of the advantages of havingfolders and it introduces problems that are sometimes subtle (becauseyou may not know the header you are actually including if there are twoof them).For example, this patch had to be created because two headers werecalled the same way: e0ea0928d5b7 ("Fix gpio includes of mt8173 platformto avoid collision."). More recently, this patch has had similarproblems: 46f9b2c3a282 ("drivers: add tzc380 support").This problem was introduced in commit 4ecca33988b9 ("Move include andsource files to logical locations"). At that time, there weren't toomany headers so it wasn't a real issue. However, time has shown thatthis creates problems.Platforms that want to preserve the way they include headers may add theremoved paths to PLAT_INCLUDES, but this is discouraged.Change-Id: I39dc53ed98f9e297a5966e723d1936d6ccf2fc8fSigned-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
Standardise header guards across codebaseAll identifiers, regardless of use, that start with two underscores arereserved. This means they can't be used in header guards.The style that this proje
Standardise header guards across codebaseAll identifiers, regardless of use, that start with two underscores arereserved. This means they can't be used in header guards.The style that this project is now to use the full name of the file incapital letters followed by 'H'. For example, for a file called"uart_example.h", the header guard is UART_EXAMPLE_H.The exceptions are files that are imported from other projects:- CryptoCell driver- dt-bindings folders- zlib headersChange-Id: I50561bf6c88b491ec440d0c8385c74650f3c106eSigned-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
libc: Fix all includes in codebaseThe codebase was using non-standard headers. It is needed to replacethem by the correct ones so that we can use the new libc headers.Change-Id: I530f71d9510cb03
libc: Fix all includes in codebaseThe codebase was using non-standard headers. It is needed to replacethem by the correct ones so that we can use the new libc headers.Change-Id: I530f71d9510cb036e69fe79823c8230afe890b9dAcked-by: Sumit Garg <sumit.garg@linaro.org>Signed-off-by: Antonio Nino Diaz <antonio.ninodiaz@arm.com>
drivers: ti: uart: Add TI specific 16550 initializationOn TI platforms the UART is disabled by default and must be explicitlyenabled using the MDR1 register.NOTE: The original definition ofhttp
drivers: ti: uart: Add TI specific 16550 initializationOn TI platforms the UART is disabled by default and must be explicitlyenabled using the MDR1 register.NOTE: The original definition ofhttp://www.ti.com/lit/ds/symlink/pc16550d.pdf has no MDR register, butmany TI SoCs implementing 16550 do have a quirky MDR registerimplemented. So, this should be enabled with TI_16550_MDR_QUIRKNOTE: In such implementation, the CSR register does not exist.Signed-off-by: Benjamin Fair <b-fair@ti.com>Signed-off-by: Nishanth Menon <nm@ti.com>Signed-off-by: Andrew F. Davis <afd@ti.com>
drivers: ti: uart: Update 16550 UART driver to support MULTI_CONSOLE_APIThis patch updates the TI 16550 console driver to support the newconsole API. The driver will continue to support the old AP
drivers: ti: uart: Update 16550 UART driver to support MULTI_CONSOLE_APIThis patch updates the TI 16550 console driver to support the newconsole API. The driver will continue to support the old API as well bychecking the MULTI_CONSOLE_API compile-time flag.Change-Id: I60a44b7ba3c35c74561824c04b8dbe3e3039324cSigned-off-by: Julius Werner <jwerner@chromium.org>
Use SPDX license identifiersTo make software license auditing simpler, use SPDX[0] licenseidentifiers instead of duplicating the license text in every file.NOTE: Files that have been imported by
Use SPDX license identifiersTo make software license auditing simpler, use SPDX[0] licenseidentifiers instead of duplicating the license text in every file.NOTE: Files that have been imported by FreeBSD have not been modified.[0]: https://spdx.org/Change-Id: I80a00e1f641b8cc075ca5a95b10607ed9ed8761aSigned-off-by: dp-arm <dimitris.papastamos@arm.com>
uart: 16550: Fix getctbz check for RDR status is to check for a bit being zero.Unfortunately, we are using a mask rather than the bit position.Further as per http://www.ti.com/lit/ds/symlink/pc1
uart: 16550: Fix getctbz check for RDR status is to check for a bit being zero.Unfortunately, we are using a mask rather than the bit position.Further as per http://www.ti.com/lit/ds/symlink/pc16550d.pdf (page 17),LSR register bit 0 is Data ready status (RDR), not bit position 2.Update the same to match the specification.Reported-by: Sekhar Nori <nsekhar@ti.com>Signed-off-by: Nishanth Menon <nm@ti.com>
Driver for 16550 UART interfaceThis patch adds driver for the 16550 UART interface. The driver is exposedas a console, which platforms can use to dump their boot/crash logs.Signed-off-by: Varun
Driver for 16550 UART interfaceThis patch adds driver for the 16550 UART interface. The driver is exposedas a console, which platforms can use to dump their boot/crash logs.Signed-off-by: Varun Wadekar <vwadekar@nvidia.com>