New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
drivers/periph/cpuid: Fix typo in doc #14080
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK.
@@ -48,7 +48,7 @@ extern "C" { | |||
/** | |||
* @brief Gets the serial number of the CPU. | |||
* | |||
* @param[out] id The serial number of the CPU of length CPU_ID_LEN (must be | |||
* @param[out] id The serial number of the CPU of length CPUID_LEN (must be |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See here:
RIOT/drivers/include/periph/cpuid.h
Lines 39 to 46 in 1f9d299
/** | |
* @def CPUID_LEN | |
* | |
* @brief The length in byte of the CPU's serial number. | |
* | |
* @note Must be defined in the CPU's @ref cpu_conf.h | |
*/ | |
#if CPUID_LEN |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK
obvious typo:
git grep CPU_ID_LEN
drivers/include/periph/cpuid.h: * @param[out] id The serial number of the CPU of length CPU_ID_LEN (must be
git grep CPUID_LEN
cpu/atmega_common/include/periph_cpu_common.h:#define CPUID_LEN (4U)
cpu/cc2538/include/periph_cpu.h:#define CPUID_LEN (8U)
cpu/cc26xx_cc13xx/include/periph_cpu_common.h:#define CPUID_LEN (16U)
cpu/efm32/include/periph_cpu.h:#define CPUID_LEN (8U)
cpu/esp32/include/periph_cpu.h:#define CPUID_LEN (7U)
cpu/esp32/startup.c: uint8_t cpu_id[CPUID_LEN];
cpu/esp32/startup.c: for (unsigned i = 0; i < CPUID_LEN; i++) {
cpu/esp8266/include/periph_cpu.h:#define CPUID_LEN (4U)
cpu/esp8266/periph/cpuid.c: memcpy(id, &(chip_id), CPUID_LEN);
cpu/ezr32wg/include/periph_cpu.h:#define CPUID_LEN (8U)
cpu/fe310/include/periph_cpu.h:#define CPUID_LEN (12U)
cpu/fe310/periph/cpuid.c: memcpy(id, &result[0], CPUID_LEN);
cpu/kinetis/include/periph_cpu.h:#define CPUID_LEN (16U)
cpu/kinetis/include/periph_cpu.h:#define CPUID_LEN (12U)
cpu/lpc1768/include/cpu_conf.h:#define CPUID_LEN (16U)
cpu/lpc1768/periph/cpuid.c: memcpy(id, &result[1], CPUID_LEN);
cpu/lpc1768/periph/cpuid.c: memset(id, 0xFF, CPUID_LEN);
cpu/mips_pic32_common/include/periph_cpu_common.h:#define CPUID_LEN (4U)
cpu/mips_pic32_common/periph/cpuid.c: memcpy(id, (uint32_t*)&DEVID, CPUID_LEN);
cpu/native/include/periph_cpu.h:#ifndef CPUID_LEN
cpu/native/include/periph_cpu.h:#define CPUID_LEN (4U)
cpu/native/periph/cpuid.c: /* Just in case _native_id is shorter than CPUID_LEN: */
cpu/native/periph/cpuid.c: size_t len = CPUID_LEN;
cpu/native/periph/cpuid.c: if (sizeof(_native_id) < CPUID_LEN) {
cpu/native/periph/cpuid.c: CPUID_LEN - sizeof(_native_id));
cpu/nrf5x_common/include/periph_cpu_common.h:#define CPUID_LEN (8U)
cpu/nrf5x_common/radio/nrfmin/nrfmin.c: uint8_t cpuid[CPUID_LEN];
cpu/nrf5x_common/radio/nrfmin/nrfmin.c: for (unsigned i = 0; i < CPUID_LEN; i++) {
cpu/sam0_common/include/periph_cpu_common.h:#define CPUID_LEN (16U)
cpu/sam0_common/periph/cpuid.c: memcpy(id, &addr[0], CPUID_LEN);
cpu/sam3/include/periph_cpu.h:#define CPUID_LEN (16U)
cpu/sam3/periph/cpuid.c: memcpy(id, (void*)cpuid, CPUID_LEN);
cpu/stm32_common/include/periph_cpu_common.h:#define CPUID_LEN (12U)
doc/doxygen/riot.doxyfile: CPUID_LEN \
drivers/include/periph/cpuid.h: * @def CPUID_LEN
drivers/include/periph/cpuid.h:#if CPUID_LEN
drivers/include/periph/cpuid.h:#endif /* CPUID_LEN */
drivers/periph_common/cpuid.c: memcpy(id, (void *)CPUID_ADDR, CPUID_LEN);
pkg/openthread/contrib/platform_random.c:#ifdef CPUID_LEN
pkg/openthread/contrib/platform_random.c: char cpu_id[CPUID_LEN];
pkg/openthread/contrib/platform_random.c: for (unsigned i = 0; i < CPUID_LEN; i++) {
sys/luid/luid.c:#if CPUID_LEN
sys/luid/luid.c: uint8_t cid[CPUID_LEN];
sys/luid/luid.c: for (size_t i = 0; i < MAX(len, CPUID_LEN); i++) {
sys/luid/luid.c: out[i % len] ^= cid[i % CPUID_LEN];
tests/periph_cpuid/main.c: uint8_t id[CPUID_LEN];
tests/periph_cpuid/main.c: printf("CPUID_LEN: %u\n", CPUID_LEN);
tests/periph_cpuid/main.c: for (unsigned int i = 0; i < CPUID_LEN; i++) {
tests/periph_cpuid/tests/01-run.py: child.expect(r'CPUID_LEN: (\d+)\r\n')
So many ACKs so promptly! Thanks :-) |
Contribution description
Just as the title says.
Testing procedure
Read the docu and confirm that it should indeed be named
CPUID_LEN
rather thanCPU_ID_LEN
.Issues/PRs references
None