upstream u-boot with additional patches for our devices/boards: https://lists.denx.de/pipermail/u-boot/2017-March/282789.html (AXP crashes) ; Gbit ethernet patch for some LIME2 revisions ; with SPI flash support
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
u-boot/fs/btrfs/dev.c

25 lines
567 B

// SPDX-License-Identifier: GPL-2.0+
/*
* BTRFS filesystem implementation for U-Boot
*
* 2017 Marek Behun, CZ.NIC, marek.behun@nic.cz
*/
#include <common.h>
#include <compiler.h>
#include <fs_internal.h>
struct blk_desc *btrfs_blk_desc;
disk_partition_t *btrfs_part_info;
int btrfs_devread(u64 address, int byte_len, void *buf)
{
lbaint_t sector;
int byte_offset;
sector = address >> btrfs_blk_desc->log2blksz;
byte_offset = address % btrfs_blk_desc->blksz;
return fs_devread(btrfs_blk_desc, btrfs_part_info, sector, byte_offset,
byte_len, buf);
}