summaryrefslogtreecommitdiffstats
path: root/sys/contrib
diff options
context:
space:
mode:
authorjmallett <jmallett@FreeBSD.org>2012-10-29 00:51:53 +0000
committerjmallett <jmallett@FreeBSD.org>2012-10-29 00:51:53 +0000
commitd209784979f373b07125e835f0b92652c65044a8 (patch)
tree79bd47cf8f480ee74b2080cd865e927a4252921c /sys/contrib
parent5278b5f8d24acfe3be944ef5075b5edaaccda681 (diff)
downloadFreeBSD-src-d209784979f373b07125e835f0b92652c65044a8.zip
FreeBSD-src-d209784979f373b07125e835f0b92652c65044a8.tar.gz
Use Simple Executive LED display routines, which correctly use the LED base
address passed from the bootloader, rather than using a hard-coded value. Make FreeBSD announce itself on the LED display similar to other kernels. Remove uses of the previous LED routines, which were under-used and only used in drivers for what seem like debugging purposes, despite those drivers being widely-tested. Remove several inlines for accessing memory that duplicate other functions which are now used instead, as they are now entirely unused.
Diffstat (limited to 'sys/contrib')
-rw-r--r--sys/contrib/octeon-sdk/cvmx-ebt3000.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/sys/contrib/octeon-sdk/cvmx-ebt3000.c b/sys/contrib/octeon-sdk/cvmx-ebt3000.c
index dbc93dd..e3332a9 100644
--- a/sys/contrib/octeon-sdk/cvmx-ebt3000.c
+++ b/sys/contrib/octeon-sdk/cvmx-ebt3000.c
@@ -52,15 +52,18 @@
*
*/
+#if !defined(__FreeBSD__) || !defined(_KERNEL)
#include "cvmx-config.h"
+#endif
#include "cvmx.h"
+#include "cvmx-ebt3000.h"
#include "cvmx-sysinfo.h"
void ebt3000_char_write(int char_position, char val)
{
/* Note: phys_to_ptr won't work here, as we are most likely going to access the boot bus. */
- void *led_base = CASTPTR(void, CVMX_ADD_SEG32(CVMX_MIPS32_SPACE_KSEG0, cvmx_sysinfo_get()->led_display_base_addr));
+ char *led_base = CASTPTR(char , CVMX_ADD_SEG32(CVMX_MIPS32_SPACE_KSEG0, cvmx_sysinfo_get()->led_display_base_addr));
if (!led_base)
return;
if (cvmx_sysinfo_get()->board_type == CVMX_BOARD_TYPE_EBT3000 && cvmx_sysinfo_get()->board_rev_major == 1)
@@ -82,10 +85,10 @@ void ebt3000_char_write(int char_position, char val)
void ebt3000_str_write(const char *str)
{
/* Note: phys_to_ptr won't work here, as we are most likely going to access the boot bus. */
- void *led_base;
+ char *led_base;
if (!cvmx_sysinfo_get()->led_display_base_addr)
return;
- led_base = CASTPTR(void, CVMX_ADD_SEG32(CVMX_MIPS32_SPACE_KSEG0, cvmx_sysinfo_get()->led_display_base_addr));
+ led_base = CASTPTR(char, CVMX_ADD_SEG32(CVMX_MIPS32_SPACE_KSEG0, cvmx_sysinfo_get()->led_display_base_addr));
if (cvmx_sysinfo_get()->board_type == CVMX_BOARD_TYPE_EBT3000 && cvmx_sysinfo_get()->board_rev_major == 1)
{
char *ptr = (char *)(led_base + 4);
OpenPOWER on IntegriCloud