Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion kernel/console/kconsole/terminal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ void Terminal::run_command(){
string cmd;
int argc = 0;
const char** argv;
string args_copy;
string args_copy = {};

if (fullcmd == args){
cmd = string_l(fullcmd);
Expand Down
4 changes: 2 additions & 2 deletions kernel/input/usb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ bool USBDriver::get_configuration(uint8_t address){
uint8_t* report_descriptor;
uint16_t report_length;

usb_device_types dev_type;
usb_device_types dev_type = UNKNOWN;

kprintf("[USB] set configuration %i for device %i", config->bConfigurationValue, address);
request_sized_descriptor(address, 0, 0, 9, 0, config->bConfigurationValue, 0, 0, 0);
Expand Down Expand Up @@ -212,4 +212,4 @@ void USBDriver::hub_enumerate(uint8_t address){

void USBDriver::poll_inputs(){
usb_manager->poll_inputs(this);
}
}
4 changes: 2 additions & 2 deletions kernel/input/xhci.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ bool XHCIDriver::check_fatal_error() {
#define XHCI_EP_CONTROL 4

bool XHCIDriver::init(){
uint64_t addr, mmio, mmio_size;
uint64_t addr = 0, mmio = 0, mmio_size = 0;
bool use_pci = false;
use_interrupts = true;
if (XHCI_BASE){
Expand Down Expand Up @@ -596,4 +596,4 @@ void XHCIDriver::handle_interrupt(){
interrupter->erdp = (uintptr_t)&event_ring.ring[event_ring.index] | (1 << 3);//Inform of latest processed event
interrupter->iman |= 1;//Clear interrupts
op->usbsts |= 1 << 3;//Clear interrupts
}
}
6 changes: 3 additions & 3 deletions kernel/kernel_processes/monitor/monitor_processes.c
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ void draw_process_view(){
int index = scroll_index;
int valid_count = 0;

process_t *proc;
process_t *proc = NULL;
while (index < MAX_PROCS) {
proc = &processes[index];
if (proc->id != 0 && proc->state != STOPPED) {
Expand All @@ -105,7 +105,7 @@ void draw_process_view(){
index++;
}

if (proc->id == 0 || valid_count < i || proc->state == STOPPED) break;
if (proc == NULL || proc->id == 0 || valid_count < i || proc->state == STOPPED) break;

string name = string_l((const char*)(uintptr_t)proc->name);
string state = string_l(parse_proc_state(proc->state));
Expand Down Expand Up @@ -173,4 +173,4 @@ process_t* start_process_monitor(){
//TODO: disabled process monitor since shortcuts seem broken on rpi
return 0x0;//create_kernel_process("procmonitor",monitor_procs, 0, 0);
#endif
}
}
4 changes: 2 additions & 2 deletions kernel/memory/mmu.c
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ void mmu_map_4kb(uint64_t va, uint64_t pa, uint64_t attr_index, uint64_t level)
return;
}

uint8_t permission;
uint8_t permission = 0;

switch (level)
{
Expand Down Expand Up @@ -277,4 +277,4 @@ void debug_mmu_address(uint64_t va){
}
kprintf("Entry: %x", l4_val);
return;
}
}