diff options
-rw-r--r-- | .readthedocs.yml | 19 | ||||
-rw-r--r-- | Makefile | 4 | ||||
-rw-r--r-- | cmd/mem.c | 9 | ||||
-rw-r--r-- | doc/conf.py | 2 | ||||
-rwxr-xr-x | doc/sphinx/parse-headers.pl | 4 | ||||
-rw-r--r-- | fs/ext4/ext4_journal.c | 3 | ||||
-rw-r--r-- | lib/zlib/trees.c | 31 | ||||
-rw-r--r-- | net/Kconfig | 4 | ||||
-rw-r--r-- | net/tftp.c | 7 | ||||
-rw-r--r-- | test/py/tests/test_fs/conftest.py | 5 | ||||
-rw-r--r-- | tools/env/fw_env.c | 3 |
11 files changed, 60 insertions, 31 deletions
diff --git a/.readthedocs.yml b/.readthedocs.yml new file mode 100644 index 0000000000..f3fb5ed51b --- /dev/null +++ b/.readthedocs.yml @@ -0,0 +1,19 @@ +# .readthedocs.yml +# Read the Docs configuration file +# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details + +# Required +version: 2 + +# Build documentation in the docs/ directory with Sphinx +sphinx: + configuration: docs/conf.py + +# Optionally build your docs in additional formats such as PDF and ePub +formats: [] + +# Optionally set the version of Python and requirements required to build your docs +# python: +# version: 3.7 +# install: +# - requirements: docs/requirements.txt @@ -1325,7 +1325,9 @@ endif # Boards with more complex image requirements can provide an .its source file # or a generator script ifneq ($(CONFIG_SPL_FIT_SOURCE),"") -U_BOOT_ITS = $(subst ",,$(CONFIG_SPL_FIT_SOURCE)) +U_BOOT_ITS := u-boot.its +$(U_BOOT_ITS): $(subst ",,$(CONFIG_SPL_FIT_SOURCE)) + $(call if_changed,copy) else ifneq ($(CONFIG_SPL_FIT_GENERATOR),"") U_BOOT_ITS := u-boot.its @@ -1144,10 +1144,8 @@ static int do_random(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) unsigned char *buf8; unsigned int i; - if (argc < 3 || argc > 4) { - printf("usage: %s <addr> <len> [<seed>]\n", argv[0]); - return 0; - } + if (argc < 3 || argc > 4) + return CMD_RET_USAGE; len = simple_strtoul(argv[2], NULL, 16); addr = simple_strtoul(argv[1], NULL, 16); @@ -1174,7 +1172,8 @@ static int do_random(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) unmap_sysmem(start); printf("%lu bytes filled with random data\n", len); - return 1; + + return CMD_RET_SUCCESS; } #endif diff --git a/doc/conf.py b/doc/conf.py index 8bb27ad9e2..93250a6aee 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -31,6 +31,8 @@ from load_config import loadConfig # If your documentation needs a minimal Sphinx version, state it here. needs_sphinx = '1.3' +latex_engine = 'xelatex' + # Add any Sphinx extension module names here, as strings. They can be # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. diff --git a/doc/sphinx/parse-headers.pl b/doc/sphinx/parse-headers.pl index d4f38262eb..c518050ffc 100755 --- a/doc/sphinx/parse-headers.pl +++ b/doc/sphinx/parse-headers.pl @@ -344,7 +344,7 @@ enums and defines and create cross-references to a Sphinx book. B<parse_headers.pl> [<options>] <C_FILE> <OUT_FILE> [<EXCEPTIONS_FILE>] -Where <options> can be: --debug, --help or --man. +Where <options> can be: --debug, --help or --usage. =head1 OPTIONS @@ -382,7 +382,7 @@ ioctl. The EXCEPTIONS_FILE contain two rules to allow ignoring a symbol or to replace the default references by a custom one. -Please read doc/doc-guide/parse-headers.rst at the Kernel's +Please read Documentation/doc-guide/parse-headers.rst at the Kernel's tree for more details. =head1 BUGS diff --git a/fs/ext4/ext4_journal.c b/fs/ext4/ext4_journal.c index 3559daf11d..f8524e5a99 100644 --- a/fs/ext4/ext4_journal.c +++ b/fs/ext4/ext4_journal.c @@ -409,6 +409,9 @@ int ext4fs_check_journal_state(int recovery_flag) char *temp_buff1 = NULL; struct ext_filesystem *fs = get_fs(); + if (le32_to_cpu(fs->sb->feature_ro_compat) & EXT4_FEATURE_RO_COMPAT_METADATA_CSUM) + return 0; + temp_buff = zalloc(fs->blksz); if (!temp_buff) return -ENOMEM; diff --git a/lib/zlib/trees.c b/lib/zlib/trees.c index a0078d08ee..3e09517ed0 100644 --- a/lib/zlib/trees.c +++ b/lib/zlib/trees.c @@ -7,27 +7,28 @@ /* * ALGORITHM * - * The "deflation" process uses several Huffman trees. The more - * common source values are represented by shorter bit sequences. + * The "deflation" process uses several Huffman trees. The more + * common source values are represented by shorter bit sequences. * - * Each code tree is stored in a compressed form which is itself - * a Huffman encoding of the lengths of all the code strings (in - * ascending order by source values). The actual code strings are - * reconstructed from the lengths in the inflate process, as described - * in the deflate specification. + * Each code tree is stored in a compressed form which is itself + * a Huffman encoding of the lengths of all the code strings (in + * ascending order by source values). The actual code strings are + * reconstructed from the lengths in the inflate process, as + * described in the deflate specification. * * REFERENCES * - * Deutsch, L.P.,"'Deflate' Compressed Data Format Specification". - * Available in ftp.uu.net:/pub/archiving/zip/doc/deflate-1.1.doc + * Deutsch, P. + * RFC 1951, DEFLATE Compressed Data Format Specification version 1.3 + * https://tools.ietf.org/html/rfc1951, 1996 * - * Storer, James A. - * Data Compression: Methods and Theory, pp. 49-50. - * Computer Science Press, 1988. ISBN 0-7167-8156-5. + * Storer, James A. + * Data Compression: Methods and Theory, pp. 49-50. + * Computer Science Press, 1988. ISBN 0-7167-8156-5. * - * Sedgewick, R. - * Algorithms, p290. - * Addison-Wesley, 1983. ISBN 0-201-06672-6. + * Sedgewick, R. + * Algorithms, p290. + * Addison-Wesley, 1983. ISBN 0-201-06672-6. */ /* @(#) $Id$ */ diff --git a/net/Kconfig b/net/Kconfig index 96bbce1778..ac6d0cf8a6 100644 --- a/net/Kconfig +++ b/net/Kconfig @@ -44,5 +44,9 @@ config TFTP_BLOCKSIZE default 1468 help Default TFTP block size. + The MTU is typically 1500 for ethernet, so a TFTP block of + 1468 (MTU minus eth.hdrs) provides a good throughput with + almost-MTU block sizes. + You can also activate CONFIG_IP_DEFRAG to set a larger block. endif # if NET diff --git a/net/tftp.c b/net/tftp.c index 585eb6ef0c..be24e63075 100644 --- a/net/tftp.c +++ b/net/tftp.c @@ -133,14 +133,9 @@ static char tftp_filename[MAX_LEN]; * almost-MTU block sizes. At least try... fall back to 512 if need be. * (but those using CONFIG_IP_DEFRAG may want to set a larger block in cfg file) */ -#ifdef CONFIG_TFTP_BLOCKSIZE -#define TFTP_MTU_BLOCKSIZE CONFIG_TFTP_BLOCKSIZE -#else -#define TFTP_MTU_BLOCKSIZE 1468 -#endif static unsigned short tftp_block_size = TFTP_BLOCK_SIZE; -static unsigned short tftp_block_size_option = TFTP_MTU_BLOCKSIZE; +static unsigned short tftp_block_size_option = CONFIG_TFTP_BLOCKSIZE; static inline int store_block(int block, uchar *src, unsigned int len) { diff --git a/test/py/tests/test_fs/conftest.py b/test/py/tests/test_fs/conftest.py index 1949f91619..ee82169c2a 100644 --- a/test/py/tests/test_fs/conftest.py +++ b/test/py/tests/test_fs/conftest.py @@ -335,8 +335,9 @@ def fs_obj_basic(request, u_boot_config): md5val.append(out.split()[0]) umount_fs(mount_dir) - except CalledProcessError: - pytest.skip('Setup failed for filesystem: ' + fs_type) + except CalledProcessError as err: + pytest.skip('Setup failed for filesystem: ' + fs_type + \ + '. {}'.format(err)) return else: yield [fs_ubtype, fs_img, md5val] diff --git a/tools/env/fw_env.c b/tools/env/fw_env.c index 381739d28d..8734663cd4 100644 --- a/tools/env/fw_env.c +++ b/tools/env/fw_env.c @@ -1647,6 +1647,9 @@ static int check_device_config(int dev) goto err; } DEVTYPE(dev) = mtdinfo.type; + if (DEVESIZE(dev) == 0 && ENVSECTORS(dev) == 0 && + mtdinfo.type == MTD_NORFLASH) + DEVESIZE(dev) = mtdinfo.erasesize; if (DEVESIZE(dev) == 0) /* Assume the erase size is the same as the env-size */ DEVESIZE(dev) = ENVSIZE(dev); |