rust-fmt all

pull/9/head
Andre Richter 6 years ago
parent 633510262d
commit c156a32411
No known key found for this signature in database
GPG Key ID: 2116C1AB102F615E

@ -64,7 +64,6 @@ register_bitfields! {
]
}
pub const GPFSEL1: *const ReadWrite<u32, GPFSEL1::Register> =
(MMIO_BASE + 0x0020_0004) as *const ReadWrite<u32, GPFSEL1::Register>;

@ -64,7 +64,6 @@ register_bitfields! {
]
}
pub const GPFSEL1: *const ReadWrite<u32, GPFSEL1::Register> =
(MMIO_BASE + 0x0020_0004) as *const ReadWrite<u32, GPFSEL1::Register>;

@ -66,7 +66,6 @@ register_bitfields! {
]
}
pub const GPFSEL1: *const ReadWrite<u32, GPFSEL1::Register> =
(MMIO_BASE + 0x0020_0004) as *const ReadWrite<u32, GPFSEL1::Register>;

@ -43,7 +43,7 @@ macro_rules! entry {
f()
}
}
};
}
/// Reset function.

@ -66,7 +66,6 @@ register_bitfields! {
]
}
pub const GPFSEL1: *const ReadWrite<u32, GPFSEL1::Register> =
(MMIO_BASE + 0x0020_0004) as *const ReadWrite<u32, GPFSEL1::Register>;

@ -43,7 +43,7 @@ macro_rules! entry {
f()
}
}
};
}
/// Reset function.

@ -66,7 +66,6 @@ register_bitfields! {
]
}
pub const GPFSEL1: *const ReadWrite<u32, GPFSEL1::Register> =
(MMIO_BASE + 0x0020_0004) as *const ReadWrite<u32, GPFSEL1::Register>;

@ -49,7 +49,9 @@ fn kernel_entry() -> ! {
// set up serial console
if uart.init(&mut mbox).is_err() {
loop { cortex_a::asm::wfe() }; // If UART fails, abort early
loop {
cortex_a::asm::wfe()
} // If UART fails, abort early
}
// get the board's unique serial number with a mailbox call

@ -43,7 +43,7 @@ macro_rules! entry {
f()
}
}
};
}
/// Reset function.

@ -66,7 +66,6 @@ register_bitfields! {
]
}
pub const GPFSEL1: *const ReadWrite<u32, GPFSEL1::Register> =
(MMIO_BASE + 0x0020_0004) as *const ReadWrite<u32, GPFSEL1::Register>;

@ -48,7 +48,9 @@ fn kernel_entry() -> ! {
// set up serial console
if uart.init(&mut mbox).is_err() {
loop { cortex_a::asm::wfe() }; // If UART fails, abort early
loop {
cortex_a::asm::wfe()
} // If UART fails, abort early
}
uart.getc(); // Press a key first before being greeted

@ -43,7 +43,7 @@ macro_rules! entry {
f()
}
}
};
}
/// Reset function.

@ -66,7 +66,6 @@ register_bitfields! {
]
}
pub const GPFSEL1: *const ReadWrite<u32, GPFSEL1::Register> =
(MMIO_BASE + 0x0020_0004) as *const ReadWrite<u32, GPFSEL1::Register>;

@ -48,7 +48,9 @@ fn kernel_entry() -> ! {
// set up serial console
if uart.init(&mut mbox).is_err() {
loop { cortex_a::asm::wfe() }; // If UART fails, abort early
loop {
cortex_a::asm::wfe()
} // If UART fails, abort early
}
uart.getc(); // Press a key first before being greeted

@ -43,7 +43,7 @@ macro_rules! entry {
f()
}
}
};
}
/// Reset function.

@ -51,7 +51,9 @@ fn kernel_entry() -> ! {
// set up serial console
if uart.init(&mut mbox, &gpio).is_err() {
loop { cortex_a::asm::wfe() }; // If UART fails, abort early
loop {
cortex_a::asm::wfe()
} // If UART fails, abort early
}
uart.getc(); // Press a key first before being greeted

@ -188,7 +188,8 @@ impl Uart {
};
// map UART0 to GPIO pins
gpio.GPFSEL1.modify(gpio::GPFSEL1::FSEL14::TXD0 + gpio::GPFSEL1::FSEL15::RXD0);
gpio.GPFSEL1
.modify(gpio::GPFSEL1::FSEL14::TXD0 + gpio::GPFSEL1::FSEL15::RXD0);
gpio.GPPUD.set(0); // enable pins 14 and 15
delays::wait_cycles(150);

Loading…
Cancel
Save