严格代码检查,修复大量错误,以及diskio.c ioctl参数大小导致的卡死问题

This commit is contained in:
zhangzheng
2025-03-23 17:35:56 +08:00
parent 749e24ddb7
commit 54b6bc9c24
139 changed files with 1317 additions and 1077 deletions

View File

@@ -39,6 +39,18 @@ void putc(int c)
{
uart_putc(uart_get_global(), c);
}
void put_bytes(const uint8_t *data, size_t len)
{
umword_t state = 0;
state = spinlock_lock(&lock);
for (int i = 0; i < len; i++)
{
uart_putc(uart_get_global(), data[i]);
}
spinlock_set(&lock, state);
}
int getc(void)
{
return uart_getc(uart_get_global());