荔枝派Zero(V3s)制作SPI Flash 启动镜像的uboot源码。
代码片段和文件信息
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2017-08-12 09:27 u-boot-3s-spi-experimental
文件 610 2017-08-12 09:27 u-boot-3s-spi-experimental.checkpatch.conf
文件 825 2017-08-12 09:27 u-boot-3s-spi-experimental.gitignore
文件 1323 2017-08-12 09:27 u-boot-3s-spi-experimental.mailmap
文件 9716 2017-08-12 09:27 u-boot-3s-spi-experimental.travis.yml
文件 1863 2017-08-12 09:27 u-boot-3s-spi-experimentalKbuild
文件 11544 2017-08-12 09:27 u-boot-3s-spi-experimentalKconfig
目录 0 2017-08-12 09:27 u-boot-3s-spi-experimentalLicenses
文件 627 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesExceptions
文件 4575 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesOFL.txt
文件 3846 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesREADME
文件 1249 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensessd-2-clause.txt
文件 1442 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensessd-3-clause.txt
文件 1864 2017-08-12 09:27 u-boot-3s-spi-experimentalLicenseseCos-2.0.txt
文件 18092 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesgpl-2.0.txt
文件 849 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesibm-pibs.txt
文件 822 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesisc.txt
文件 25383 2017-08-12 09:27 u-boot-3s-spi-experimentalLicenseslgpl-2.0.txt
文件 26530 2017-08-12 09:27 u-boot-3s-spi-experimentalLicenseslgpl-2.1.txt
文件 1337 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesx11.txt
文件 11770 2017-08-12 09:27 u-boot-3s-spi-experimentalMAINTAINERS
文件 53473 2017-08-12 09:27 u-boot-3s-spi-experimentalMakefile
文件 223798 2017-08-12 09:27 u-boot-3s-spi-experimentalREADME
目录 0 2017-08-12 09:27 u-boot-3s-spi-experimentalapi
文件 252 2017-08-12 09:27 u-boot-3s-spi-experimentalapiMakefile
文件 1873 2017-08-12 09:27 u-boot-3s-spi-experimentalapiREADME
文件 14370 2017-08-12 09:27 u-boot-3s-spi-experimentalapiapi.c
文件 1145 2017-08-12 09:27 u-boot-3s-spi-experimentalapiapi_display.c
文件 2030 2017-08-12 09:27 u-boot-3s-spi-experimentalapiapi_net.c
文件 844 2017-08-12 09:27 u-boot-3s-spi-experimentalapiapi_platform-arm.c
文件 702 2017-08-12 09:27 u-boot-3s-spi-experimentalapiapi_platform-mips.c
............此处省略14269个文件信息
/*
* (C) Copyright 2007 Semihalf
*
* Written by: Rafal Jaworowski
*
* SPDX-License-Identifier: GPL-2.0+
*/
#include
#include
#include
#include
#include
#include
#include
#include “api_private.h“
#define DEBUG
#undef DEBUG
/*****************************************************************************
*
* This is the API core.
*
* API_ functions are part of U-Boot code and constitute the lowest level
* calls:
*
* - they know what values they need as arguments
* - their direct return value pertains to the API_ “shell“ itself (0 on
* success some error code otherwise)
* - if the call returns a value it is buried within arguments
*
****************************************************************************/
#ifdef DEBUG
#define debugf(fmt args...) do { printf(“%s(): “ __func__); printf(fmt ##args); } while (0)
#else
#define debugf(fmt args...)
#endif
typedef int (*cfp_t)(va_list argp);
static int calls_no;
/*
* pseudo signature:
*
* int API_getc(int *c)
*/
static int API_getc(va_list ap)
{
int *c;
if ((c = (int *)va_arg(ap uintptr_t)) == NULL)
return API_EINVAL;
*c = getc();
return 0;
}
/*
* pseudo signature:
*
* int API_tstc(int *c)
*/
static int API_tstc(va_list ap)
{
int *t;
if ((t = (int *)va_arg(ap uintptr_t)) == NULL)
return API_EINVAL;
*t = tstc();
return 0;
}
/*
* pseudo signature:
*
* int API_putc(char *ch)
*/
static int API_putc(va_list ap)
{
char *c;
if ((c = (char *)va_arg(ap uintptr_t)) == NULL)
return API_EINVAL;
putc(*c);
return 0;
}
/*
* pseudo signature:
*
* int API_puts(char **s)
*/
static int API_puts(va_list ap)
{
char *s;
if ((s = (char *)va_arg(ap uintptr_t)) == NULL)
return API_EINVAL;
puts(s);
return 0;
}
/*
* pseudo signature:
*
* int API_reset(void)
*/
static int API_reset(va_list ap)
{
do_reset(NULL 0 0 NULL);
/* NOT REACHED */
return 0;
}
/*
* pseudo signature:
*
* int API_get_sys_info(struct sys_info *si)
*
* fill out the sys_info struct containing selected parameters about the
* machine
*/
static int API_get_sys_info(va_list ap)
{
struct sys_info *si;
si = (struct sys_info *)va_arg(ap uintptr_t);
if (si == NULL)
return API_ENOMEM;
return (platform_sys_info(si)) ? 0 : API_ENODEV;
}
/*
* pseudo signature:
*
* int API_udelay(unsigned long *udelay)
*/
static int API_udelay(va_list ap)
{
unsigned long *d;
if ((d = (unsigned long *)va_arg(ap unsigned long)) == NULL)
return API_EINVAL;
udelay(*d);
return 0;
}
/*
* pseudo signature:
*
* int API_get_timer(unsigned long *current unsigned long *base)
*/
static int API_get_timer(va_list ap)
{
unsigned long *base *cur;
cur = (unsigned long *)va_arg(ap unsigned long);
if (cur == NULL)
return API_EINVAL;
base = (unsigned long *)va_arg(ap unsigned long);
if (base == NULL)
return API_EINVAL;
*cur = get_timer(*base);
return
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2017-08-12 09:27 u-boot-3s-spi-experimental
文件 610 2017-08-12 09:27 u-boot-3s-spi-experimental.checkpatch.conf
文件 825 2017-08-12 09:27 u-boot-3s-spi-experimental.gitignore
文件 1323 2017-08-12 09:27 u-boot-3s-spi-experimental.mailmap
文件 9716 2017-08-12 09:27 u-boot-3s-spi-experimental.travis.yml
文件 1863 2017-08-12 09:27 u-boot-3s-spi-experimentalKbuild
文件 11544 2017-08-12 09:27 u-boot-3s-spi-experimentalKconfig
目录 0 2017-08-12 09:27 u-boot-3s-spi-experimentalLicenses
文件 627 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesExceptions
文件 4575 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesOFL.txt
文件 3846 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesREADME
文件 1249 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensessd-2-clause.txt
文件 1442 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensessd-3-clause.txt
文件 1864 2017-08-12 09:27 u-boot-3s-spi-experimentalLicenseseCos-2.0.txt
文件 18092 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesgpl-2.0.txt
文件 849 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesibm-pibs.txt
文件 822 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesisc.txt
文件 25383 2017-08-12 09:27 u-boot-3s-spi-experimentalLicenseslgpl-2.0.txt
文件 26530 2017-08-12 09:27 u-boot-3s-spi-experimentalLicenseslgpl-2.1.txt
文件 1337 2017-08-12 09:27 u-boot-3s-spi-experimentalLicensesx11.txt
文件 11770 2017-08-12 09:27 u-boot-3s-spi-experimentalMAINTAINERS
文件 53473 2017-08-12 09:27 u-boot-3s-spi-experimentalMakefile
文件 223798 2017-08-12 09:27 u-boot-3s-spi-experimentalREADME
目录 0 2017-08-12 09:27 u-boot-3s-spi-experimentalapi
文件 252 2017-08-12 09:27 u-boot-3s-spi-experimentalapiMakefile
文件 1873 2017-08-12 09:27 u-boot-3s-spi-experimentalapiREADME
文件 14370 2017-08-12 09:27 u-boot-3s-spi-experimentalapiapi.c
文件 1145 2017-08-12 09:27 u-boot-3s-spi-experimentalapiapi_display.c
文件 2030 2017-08-12 09:27 u-boot-3s-spi-experimentalapiapi_net.c
文件 844 2017-08-12 09:27 u-boot-3s-spi-experimentalapiapi_platform-arm.c
文件 702 2017-08-12 09:27 u-boot-3s-spi-experimentalapiapi_platform-mips.c
............此处省略14269个文件信息
版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容, 请发送邮件举报,一经查实,本站将立刻删除。
评论列表(条)