Fix typos (#3645)
This commit is contained in:
parent
b6c8a85f33
commit
ca8d008a2e
|
@ -210,7 +210,7 @@ void spi_mast_blkget(uint8 spi_no, size_t bitlen, uint8 *data)
|
|||
os_memcpy((void *)data, (void *)SPI_W0(spi_no), aligned_len);
|
||||
}
|
||||
|
||||
static uint32 swap_endianess(uint32 n)
|
||||
static uint32 swap_endianness(uint32 n)
|
||||
{
|
||||
return ((n & 0xff) << 24) |
|
||||
((n & 0xff00) << 8) |
|
||||
|
@ -248,10 +248,10 @@ void spi_mast_set_mosi(uint8 spi_no, uint16 offset, uint8 bitlen, uint32 data)
|
|||
|
||||
// transfer Wn to buf
|
||||
spi_buf.word[1] = READ_PERI_REG(SPI_W0(spi_no) + wn*4);
|
||||
spi_buf.word[1] = swap_endianess(spi_buf.word[1]);
|
||||
spi_buf.word[1] = swap_endianness(spi_buf.word[1]);
|
||||
if (wn < 15) {
|
||||
spi_buf.word[0] = READ_PERI_REG(SPI_W0(spi_no) + (wn+1)*4);
|
||||
spi_buf.word[0] = swap_endianess(spi_buf.word[0]);
|
||||
spi_buf.word[0] = swap_endianness(spi_buf.word[0]);
|
||||
}
|
||||
|
||||
shift = 64 - (offset & 0x1f) - bitlen;
|
||||
|
@ -259,9 +259,9 @@ void spi_mast_set_mosi(uint8 spi_no, uint16 offset, uint8 bitlen, uint32 data)
|
|||
spi_buf.dword |= (uint64)data << shift;
|
||||
|
||||
if (wn < 15) {
|
||||
WRITE_PERI_REG(SPI_W0(spi_no) + (wn+1)*4, swap_endianess(spi_buf.word[0]));
|
||||
WRITE_PERI_REG(SPI_W0(spi_no) + (wn+1)*4, swap_endianness(spi_buf.word[0]));
|
||||
}
|
||||
WRITE_PERI_REG(SPI_W0(spi_no) + wn*4, swap_endianess(spi_buf.word[1]));
|
||||
WRITE_PERI_REG(SPI_W0(spi_no) + wn*4, swap_endianness(spi_buf.word[1]));
|
||||
|
||||
return;
|
||||
}
|
||||
|
@ -293,10 +293,10 @@ uint32 spi_mast_get_miso(uint8 spi_no, uint16 offset, uint8 bitlen)
|
|||
|
||||
// transfer Wn to buf
|
||||
spi_buf.word[1] = READ_PERI_REG(SPI_W0(spi_no) + wn*4);
|
||||
spi_buf.word[1] = swap_endianess(spi_buf.word[1]);
|
||||
spi_buf.word[1] = swap_endianness(spi_buf.word[1]);
|
||||
if (wn < 15) {
|
||||
spi_buf.word[0] = READ_PERI_REG(SPI_W0(spi_no) + (wn+1)*4);
|
||||
spi_buf.word[0] = swap_endianess(spi_buf.word[0]);
|
||||
spi_buf.word[0] = swap_endianness(spi_buf.word[0]);
|
||||
}
|
||||
|
||||
result = (uint32)(spi_buf.dword >> (64 - ((offset & 0x1f) + bitlen)));
|
||||
|
|
|
@ -51,7 +51,7 @@ extern "C" {
|
|||
* 'a' is expected to be 'higher' (without overflow) than 'b'. */
|
||||
#define LWIP_U32_DIFF(a, b) (((a) >= (b)) ? ((a) - (b)) : (((a) + ((b) ^ 0xFFFFFFFF) + 1)))
|
||||
|
||||
/* Endianess-optimized shifting of two u8_t to create one u16_t */
|
||||
/* Endianness-optimized shifting of two u8_t to create one u16_t */
|
||||
#if BYTE_ORDER == LITTLE_ENDIAN
|
||||
#define LWIP_MAKE_U16(a, b) ((a << 8) | b)
|
||||
#else
|
||||
|
|
|
@ -75,7 +75,7 @@
|
|||
* @return host order (!) lwip checksum (non-inverted Internet sum)
|
||||
*
|
||||
* @note accumulator size limits summable length to 64k
|
||||
* @note host endianess is irrelevant (p3 RFC1071)
|
||||
* @note host endianness is irrelevant (p3 RFC1071)
|
||||
*/
|
||||
static u16_t ICACHE_FLASH_ATTR
|
||||
lwip_standard_chksum(void *dataptr, u16_t len)
|
||||
|
|
|
@ -1111,7 +1111,7 @@ int mbedtls_aes_crypt_cbc( mbedtls_aes_context *ctx,
|
|||
|
||||
#if defined(MBEDTLS_CIPHER_MODE_XTS)
|
||||
|
||||
/* Endianess with 64 bits values */
|
||||
/* Endianness with 64 bits values */
|
||||
#ifndef GET_UINT64_LE
|
||||
#define GET_UINT64_LE(n,b,i) \
|
||||
{ \
|
||||
|
@ -1147,7 +1147,7 @@ typedef unsigned char mbedtls_be128[16];
|
|||
*
|
||||
* This function multiplies a field element by x in the polynomial field
|
||||
* representation. It uses 64-bit word operations to gain speed but compensates
|
||||
* for machine endianess and hence works correctly on both big and little
|
||||
* for machine endianness and hence works correctly on both big and little
|
||||
* endian machines.
|
||||
*/
|
||||
static void mbedtls_gf128mul_x_ble( unsigned char r[16],
|
||||
|
|
|
@ -155,7 +155,7 @@ static int gettoalign (size_t len, Header *h, int opt, size_t size) {
|
|||
|
||||
|
||||
/*
|
||||
** options to control endianess and alignment
|
||||
** options to control endianness and alignment
|
||||
*/
|
||||
static void controloptions (lua_State *L, int opt, const char **fmt,
|
||||
Header *h) {
|
||||
|
|
Loading…
Reference in New Issue