u-boot/include
Tom Rini 48fd7e9699 Merge patch series "Fix IOVA allocation in Apple dart iommu after global LMB mem map changes"
Janne Grunau <j@jannau.net> says:

The changes in "Make LMB memory map global and persistent" [1] break
mapping DMA memory in the USB xHCI driver when using the apple_dart
iommu present on Apple silicon systems.

The IOVA space used by the u-boot driver (low 4GB) and physical memory
do not overlap. The physical memory on this systems starts depending on
the SoC either at 0x10_0000_0000 or 0x100_0000_0000. It make no sense to
manage these distinct regions in a single LMB map. In addition every
device has its own iommu and IO address space so sharing a single memory
map between all iommu instances is not necessary.

To fix this issue restore the used subset (add, alloc and free) of the
previous pointer based LMB interface with "io_" as prefix.

To ensure that low level lmb functions do not use the global LMB
variable reorder lib/lmb.c so that the variable is not visible.

Tested with patches from my "Fix device removal order for Apple dart
iommu" series [2] to fix a separate issue.

The cosmetic commit has two checkpatch warnings in existing code which I
ignored.

[1] https://lore.kernel.org/u-boot/20240826115940.3233167-1-sughosh.ganu@linaro.org/
[2] https://lore.kernel.org/u-boot/20241031-iommu_apple_dart_ordering-v1-0-8a6877946d6b@jannau.net/

Link: https://lore.kernel.org/r/20241111-io_lmb_apple_dart_iommu-v3-0-32c05da51d72@jannau.net
Signed-off-by: Tom Rini <trini@konsulko.com>
2024-11-11 09:11:55 -06:00
..
acpi arm: cpu: Add ACPI parking protocol support 2024-10-27 17:24:13 -06:00
asm-generic test: Allow saving and restoring the bloblist 2024-11-03 21:27:12 -06:00
broadcom
cavium
clk
configs Merge tag 'u-boot-rockchip-20241111' of https://source.denx.de/u-boot/custodians/u-boot-rockchip 2024-11-11 07:25:25 -06:00
cramfs
crypto lib/crypto: Adapt mscode_parser to MbedTLS 2024-10-14 17:58:49 -06:00
dm dm: core: Add a function to see if a device exists 2024-11-03 21:27:12 -06:00
dt-bindings dt-bindings: Drop unused RZ/G2L devicetree bindings 2024-11-10 19:36:39 +01:00
env board: tegra: convert boards to text env 2024-10-13 17:20:26 +03:00
faraday
firmware/imx/sci
fsl-mc
jffs2
k210
keys
linux mtd: spi-nor: Rename SPI_ADVANCE to SPI_STACKED_PARALLEL 2024-10-31 10:49:47 -06:00
lzma
meson
mtd include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
mvebu
net
power power: pmic/regulator: Support pca9452 2024-10-10 12:17:46 -06:00
reboot-mode
renesas
samsung
soc/qcom
spmi
tee
test test: Allow saving and restoring the bloblist 2024-11-03 21:27:12 -06:00
u-boot cyclic: introduce u-boot/schedule.h 2024-10-23 06:52:38 +02:00
usb usb: tcpm: add core framework 2024-10-17 03:12:47 +02:00
valgrind
xen
zfs
_exports.h
abuf.h
ACEX1K.h
adc.h
addr_map.h
ahci.h
alist.h alist: Add a way to efficiently filter an alist 2024-11-03 21:27:12 -06:00
altera.h
android_ab.h cmd: bcb: introduce 'ab_dump' command to print BCB block content 2024-10-24 09:45:55 +02:00
android_bootloader_message.h
android_image.h image: android: use ulong for kernel address 2024-10-24 09:48:14 +02:00
ansi.h
api.h
api_public.h
arm_ffa.h
arm_ffa_priv.h
armcoremodule.h
asm-offsets.h
ata.h
atf_common.h Update the ARM trusted firmware git URL 2024-10-03 09:08:29 -06:00
atmel_hlcdc.h
atmel_lcd.h
atmel_lcdc.h
atmel_mci.h
atsha204a-i2c.h
audio_codec.h
autoboot.h
avb_verify.h
axi.h
axp152.h
axp209.h
axp221.h
axp305.h
axp809.h
axp818.h
axp_pmic.h
backlight.h
bcb.h
bcd.h
binman.h
binman_sym.h
bios_emul.h
bitfield.h
blk.h block: make blk_create_device() static 2024-10-24 11:20:58 -06:00
blkmap.h
bloblist.h arm: cpu: Add ACPI parking protocol support 2024-10-27 17:24:13 -06:00
bmp_layout.h
board_f.h board_f: Move new_bloblist to boardf 2024-08-26 14:05:38 -06:00
boot_fit.h
bootcount.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
bootdev.h bootstd: Add stub for bootdev_setup_for_sibling_blk() 2024-10-03 11:52:16 -06:00
bootflow.h
bootm.h
bootmeth.h bootstd: Add command to enable setting of bootmeth specific properties 2024-10-15 10:24:27 -06:00
bootretry.h
bootstage.h bootstage: Allow counting memory without strings 2024-10-25 14:22:24 -06:00
bootstd.h
bouncebuf.h
btrfs.h
bus_vcxk.h
button.h
bzlib.h
cache.h
capitalization.h
cbfs.h
cedit.h expo: Add forward declaration for udevice to cedit 2024-10-18 14:10:22 -06:00
charset.h
circbuf.h
cli.h
cli_hush.h
clk-uclass.h
clk.h
clock_legacy.h
cmd_spl.h
command.h
common_timing_params.h
compiler.h
config_distro_bootcmd.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
config_fallbacks.h
config_fsl_chain_trust.h
config_phylib_all_drivers.h
console.h dm: usb: Deal with USB keyboard persisting across tests 2024-09-18 13:01:00 -06:00
cortina.h
cp437.h
cp1250.h
cpsw.h
cpu.h
cpu_func.h cpu_func.h: provide noncached_set_region prototype to fix build 2024-10-29 16:17:32 -06:00
cros_ec.h
cros_ec_message.h
crypt.h
ctype.h
cyclic.h cyclic: make cyclic_run static 2024-10-23 06:52:38 +02:00
ddr_spd.h
debug_uart.h
dfu.h dfu: define a callback function for the dfu_alt_info environment variable 2024-10-01 10:55:09 +02:00
dialog_pmic.h
display.h
display_options.h
div64.h
dm-demo.h
dm.h
dma-uclass.h
dma.h
dsi_host.h
dt-structs.h
dt_table.h
dw_hdmi.h
dwc3-omap-uboot.h
dwc3-sti-glue.h
dwc3-uboot.h
dwc_ahsata.h
dwmmc.h
e500.h
ec_commands.h
edid.h
eeprom.h
eeprom_field.h
eeprom_layout.h
efi.h sandbox: Report host default-filename in native mode 2024-11-09 10:01:47 +01:00
efi_api.h
efi_config.h
efi_driver.h
efi_dt_fixup.h
efi_load_initrd.h
efi_loader.h efi_loader: Change efi_dp_from_mem() to use size 2024-11-09 09:56:45 +01:00
efi_riscv.h
efi_rng.h
efi_selftest.h
efi_tcg2.h
efi_variable.h efi_loader: correct efi_set_variable_int() description 2024-09-21 10:59:06 +02:00
elf.h
env.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
env_attr.h
env_callback.h Merge patch series "Tidy up use of 'SPL' and CONFIG_SPL_BUILD" 2024-10-11 12:23:25 -06:00
env_default.h global_data: Drop pci_bootdelay 2024-08-26 14:05:38 -06:00
env_flags.h
env_internal.h global_data: Use less space for environment fields 2024-08-26 14:05:38 -06:00
erofs.h
errno.h
eth_phy.h
ethsw.h
event.h events: correct event_uninit() description 2024-09-21 11:02:25 +02:00
event_internal.h
exception.h
expo.h x86: coreboot: Allow building an expo for editing CMOS config 2024-11-03 21:27:12 -06:00
exports.h
ext4fs.h fs: ext4: implement opendir, readdir, closedir 2024-11-01 13:37:58 -06:00
ext_common.h fs: ext4: document struct ext2_inode 2024-10-30 21:44:39 +01:00
extcon.h
extension_board.h
extlinux.h
fastboot-internal.h
fastboot.h
fat.h
fb_mmc.h
fb_nand.h
fdt.h
fdt_region.h
fdt_simplefb.h
fdt_support.h rockchip: board: Increase rng-seed size to make it sufficient for modern Linux 2024-10-26 10:46:47 +08:00
fdtdec.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
fis.h
flash.h flash: prefix error codes with FL_ 2024-09-24 13:41:20 -06:00
fm_eth.h
fpga.h
fs.h fs: improve API documentation 2024-10-30 21:44:38 +01:00
fs_internal.h
fs_loader.h
fsl_csu.h
fsl_ddr.h
fsl_ddr_dimm_params.h
fsl_ddr_sdram.h
fsl_ddrc_version.h
fsl_devdis.h
fsl_dspi.h
fsl_dtsec.h
fsl_errata.h
fsl_esdhc.h
fsl_esdhc_imx.h mmc: fsl_esdhc_imx: Reset tuning logic 2024-10-04 09:15:15 -03:00
fsl_fman.h
fsl_ifc.h
fsl_immap.h
fsl_lpuart.h
fsl_mdio.h
fsl_memac.h
fsl_mmdc.h
fsl_pmic.h
fsl_qbman.h
fsl_qe.h
fsl_sec.h
fsl_sec_mon.h
fsl_secboot_err.h
fsl_sfp.h
fsl_tgec.h
fsl_usb.h
fsl_validate.h
fsl_wdog.h
fuse.h
fuzzing_engine.h
fwu.h fwu: check all images for transitioning out of Trial State 2024-09-19 10:52:50 +03:00
fwu_mdata.h
g_dnl.h
gdsys_fpga.h
generic-phy.h phy: Extend generic_setup_phy() with PHY mode and submode 2024-09-09 17:18:04 +02:00
getopt.h doc: include/getopt.h: remove comments confusing Sphinx 2024-09-21 10:58:38 +02:00
gsc.h
gt64120.h
gzip.h gzip: Correct function comment for gunzip() 2024-10-03 11:52:16 -06:00
handoff.h global_data: Drop spl_handoff 2024-08-26 14:05:38 -06:00
hang.h
hash.h
hda_codec.h
hexdump.h
host_arch.h
hw_sha.h
hwconfig.h
hwspinlock.h
i2c.h
i2c_eeprom.h
i2s.h
i8042.h
ide.h
image-android-dt.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
image-sparse.h
image.h Merge patch series "Make LMB memory map global and persistent" 2024-09-03 14:09:30 -06:00
imx8image.h tools: imx8image: add possibility to skip dcd 2024-11-09 08:54:19 -03:00
imx_container.h
imx_lpi2c.h
imx_sip.h
imx_thermal.h
imximage.h
init.h
initcall.h
input.h
interrupt.h
inttypes.h
iommu.h
iomux.h
ioports.h
iotrace.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
ipu_pixfmt.h
irq.h drivers: misc: irq-uclass: Update irq_get_by_index 2024-10-27 17:24:13 -06:00
irq_func.h cmd: irq: Move do_irqinfo() prototype to a header file 2024-10-17 15:38:50 -06:00
k3-avs.h
k3-clk.h
k3-ddrss.h
k3-dev.h
key_matrix.h
keyboard.h
kgdb.h
lattice.h
led.h doc: introduce led.rst documentation 2024-10-10 16:02:20 -06:00
libata.h
libtizen.h
limits.h mbedtls: add mbedtls into the build system 2024-10-14 17:58:12 -06:00
linker_lists.h
lmb.h Merge patch series "Fix IOVA allocation in Apple dart iommu after global LMB mem map changes" 2024-11-11 09:11:55 -06:00
log.h log: Add a new category for tests 2024-11-03 21:27:12 -06:00
mailbox-uclass.h
mailbox.h
malloc.h common: Tidy up how malloc() is inited 2024-10-25 14:22:24 -06:00
mapmem.h
marvell_phy.h
mc13892.h
mcheck.h
media_bus_format.h
memalign.h
membuff.h
menu.h bootmenu: add reprint check 2024-11-04 16:41:38 -06:00
micrel.h
miiphy.h
mipi_display.h
mipi_dsi.h
misc.h
mm_communication.h
mmc.h Merge patch series "Tidy up use of 'SPL' and CONFIG_SPL_BUILD" 2024-10-11 12:23:25 -06:00
mpc8xx.h
mpc8xx_irq.h
mpc83xx.h
mpc85xx.h
msc01.h
mtd.h
mtd_node.h
mux-internal.h
mux.h Mark a few functions static inline 2024-10-24 11:21:48 -06:00
mv88e6352.h
mvebu_mmc.h
mxs_nand.h
nand.h
ndisc.h
net-common.h net: lwip: add TFTP support and tftpboot command 2024-10-16 11:11:56 -06:00
net-legacy.h net: lwip: add DHCP support and dhcp commmand 2024-10-16 11:11:56 -06:00
net-lwip.h net: lwip: add wget command 2024-10-16 11:11:56 -06:00
net.h net: split net into net{,-common,-legacy,-lwip} 2024-10-16 11:11:56 -06:00
net6.h
netdev.h
ns16550.h
nuvoton_nct6102d.h
nvme.h
nvmem.h
nvmxip.h
of_live.h
omap3_spi.h
onenand_uboot.h
opensbi.h
os.h Prepare v2024.10-rc6 2024-09-30 17:48:12 -06:00
p2sb.h
palmas.h
panel.h
part.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
part_efi.h
pca953x.h
pch.h
pci.h
pci_ep.h
pci_gt64120.h
pci_ids.h net: dwc_eth_qos: Add glue driver for Intel MAC 2024-09-03 09:12:00 -06:00
pci_msc01.h
pci_rom.h
pci_tegra.h
pe.h
phy-mipi-dphy.h
phy-sun4i-usb.h
phy.h
phy_interface.h
phys2bus.h
physmem.h
post.h
power-domain-uclass.h
power-domain.h
ppc_asm.tmpl
ppc_defs.h
pvblock.h
pwm.h
pwrseq.h
pxe_utils.h boot: Add logic to enable booting from fallback option 2024-10-15 10:24:27 -06:00
qfw.h
ram.h
rand.h
rc4.h
regmap.h
relocate.h
remoteproc.h
reset-uclass.h
reset.h
rkmtd.h include: export uuid.h 2024-09-12 17:35:37 +02:00
rng.h
rtc.h
rtc_def.h
s_record.h
samsung-usb-phy-uboot.h
sandbox-adc.h
sandbox-clk.h
sandbox-sm.h
sandbox_efi_capsule.h sandbox: switch to dynamic UUIDs 2024-09-12 17:35:37 +02:00
sandbox_host.h
sandboxfs.h
sandboxtee.h
sata.h
scmi_agent-uclass.h
scmi_agent.h
scmi_protocols.h
scp03.h
scsi.h
scsi_emul.h
sdhci.h
sdp.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
search.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
semihosting.h
semihostingfs.h
serial.h Merge patch series "Implement ACPI on aarch64" 2024-10-27 18:44:13 -06:00
sh_pfc.h
signatures.h
sl28cpld.h
slre.h
sm-uclass.h
sm.h
smbios.h
smem.h
smsc_lpc47m.h
smsc_sio1007.h
soc.h
sort.h
sound.h
sparse_defs.h
sparse_format.h
spartan2.h
spartan3.h
spd.h
spd_sdram.h
spi-mem.h
spi.h mtd: spi-nor: Fix integer overflow in stacked memories support 2024-11-10 20:21:07 -06:00
spi_flash.h spi: add DM_SPI_FLASH compatibility inline functions 2024-10-24 09:41:52 +02:00
spl.h spl: Rename SPL_TPL_NAME and SPL_TPL_PROMPT 2024-10-11 11:44:48 -06:00
spl_gpio.h drivers: tegra_gpio: add early SPL functions 2024-10-13 17:20:26 +03:00
spl_load.h spl: spl_load: fix comparison between negative error code and unsigned size 2024-09-10 13:15:13 -06:00
splash.h
squashfs.h
status_led.h common: board_r: rework BOOT LED handling 2024-10-10 16:02:20 -06:00
stdint.h
stdio.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
stdio_dev.h
stdlib.h mbedtls: add mbedtls into the build system 2024-10-14 17:58:12 -06:00
stm32_rcc.h
stratixII.h
string.h
sunxi_gpio.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
sunxi_image.h
sy8106a.h
syscon.h
sysinfo.h
sysreset.h
system-constants.h
tables_csum.h
tca642x.h
tee.h
tegra-kbc.h
thermal.h
thor.h
ti-usb-phy-uboot.h
time.h
timer.h
timestamp.h
tlv_eeprom.h
tmu.h
tpm-common.h
tpm-v1.h
tpm-v2.h
tpm_api.h
tpm_tcg2.h
tps6586x.h
trace.h
tsec.h
tsi148.h
turris-omnia-mcu-interface.h
twl4030.h
ubi_uboot.h
ubifs_uboot.h
ubispl.h
uboot_aes.h
ufs.h
universe.h
upl.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
usb.h dm: usb: Deal with USB keyboard persisting across tests 2024-09-18 13:01:00 -06:00
usb_cdc_acm.h
usb_defs.h
usb_ether.h
usb_mass_storage.h
usbdescriptors.h
usbdevice.h
usbroothubdes.h
vbe.h include: Use CONFIG_XPL_BUILD instead of CONFIG_SPL_BUILD 2024-10-11 11:44:48 -06:00
versalpl.h
version.h
version_string.h
vesa.h
video.h video: Fix VNBYTES() macro comment 2024-10-22 19:51:23 +02:00
video_bridge.h
video_console.h video: Avoid starting a new line to close to the bottom 2024-10-18 14:10:22 -06:00
video_font.h
video_font_4x6.h
video_font_8x16.h
video_font_data.h
video_font_sun12x22.h
video_font_ter16x32.h
video_osd.h
virtex2.h
virtio.h
virtio_ring.h
virtio_types.h
vsc7385.h
vsc9953.h
vsprintf.h
vxworks.h
w1-eeprom.h
w1.h
wait_bit.h
watchdog.h watchdog.h: change include of cyclic.h to u-boot/schedule.h 2024-10-23 06:52:38 +02:00
wdt.h
winbond_w83627.h
xen.h
xilinx.h
xyzModem.h
zfs_common.h
zynq_bootimg.h
zynqmp_firmware.h
zynqmppl.h
zynqpl.h