mirror of
https://github.com/mmueller41/genode.git
synced 2026-01-21 12:32:56 +01:00
lx_kit & lx_emul: use generic platform API
* Remove wrapper for legacy x86 platform API * Move PCI configuration space quirks to corresponding driver (pc_usb_host_drv, pc_wifi_drv, pc_intel_fb_drv) * Adapt driver test run-scripts to changed configuration Ref genodelabs/genode#4578
This commit is contained in:
committed by
Christian Helmuth
parent
9f9a5186e0
commit
5528434fb6
@@ -25,11 +25,16 @@ SRC_C += lx_emul/shadow/lib/devres.c
|
||||
SRC_C += lx_emul/shadow/lib/smp_processor_id.c
|
||||
SRC_C += lx_emul/shadow/mm/memblock.c
|
||||
SRC_C += lx_emul/shadow/mm/page_alloc.c
|
||||
SRC_CC += lx_emul/pci_config_space.cc
|
||||
SRC_CC += lx_emul/pci_init.cc
|
||||
SRC_C += lx_emul/shadow/drivers/pci/host-bridge.c
|
||||
SRC_C += lx_emul/shadow/drivers/pci/pci.c
|
||||
SRC_C += lx_emul/shadow/drivers/pci/pci-sysfs.c
|
||||
SRC_C += lx_emul/shadow/drivers/pci/search.c
|
||||
SRC_C += lx_emul/shadow/drivers/pci/setup-irq.c
|
||||
SRC_C += lx_emul/shadow/drivers/pci/setup-res.c
|
||||
SRC_CC += lx_emul/pci.cc
|
||||
SRC_CC += lx_emul/pci_bus.c
|
||||
SRC_CC += lx_kit/device.cc
|
||||
SRC_CC += lx_kit/memory_dma.cc
|
||||
SRC_CC += lx_kit/spec/x86/platform.cc
|
||||
|
||||
SRC_C += lx_emul/shadow/fs/sysfs/dir.c
|
||||
SRC_C += lx_emul/shadow/fs/sysfs/file.c
|
||||
|
||||
@@ -25,7 +25,6 @@ SRC_C += lx_socket_call.c
|
||||
|
||||
SRC_C += $(notdir $(wildcard $(TARGET_LIB_DIR)/generated_dummies.c))
|
||||
SRC_C += lx_emul/common_dummies.c
|
||||
SRC_C += lx_emul/spec/x86/pci.c
|
||||
|
||||
CC_C_OPT += -I$(LX_SRC_DIR)/drivers/net/wireless/intel/iwlwifi
|
||||
CC_C_OPT += -I$(LX_SRC_DIR)/include/linux
|
||||
|
||||
@@ -2,6 +2,10 @@
|
||||
# Content hosted in the dde_linux repository
|
||||
#
|
||||
|
||||
content: include/pci
|
||||
include/pci:
|
||||
mkdir -p $(dir $@); cp -r $(GENODE_DIR)/repos/os/$@ $(dir $@)
|
||||
|
||||
MIRRORED_FROM_DDE_LINUX := src/lib/lx_emul \
|
||||
src/lib/lx_kit \
|
||||
src/include/lx_emul \
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
_/raw/test_usb_host_drv-pc
|
||||
_/src/acpi_drv
|
||||
_/src/pci_decode
|
||||
_/src/pc_usb_host_drv
|
||||
_/src/platform_drv
|
||||
_/src/report_rom
|
||||
|
||||
@@ -15,6 +15,24 @@
|
||||
<service name="Usb">
|
||||
<default-policy> <child name="usb_drv"/> </default-policy> </service>
|
||||
|
||||
<start name="report_rom" caps="70">
|
||||
<resource name="RAM" quantum="1M"/>
|
||||
<provides>
|
||||
<service name="ROM" />
|
||||
<service name="Report" />
|
||||
</provides>
|
||||
<config>
|
||||
<policy label="pci_decode -> system" report="acpi_drv -> acpi"/>
|
||||
<policy label="platform_drv -> devices" report="pci_decode -> devices"/>
|
||||
</config>
|
||||
<route>
|
||||
<service name="LOG"> <parent/> </service>
|
||||
<service name="PD"> <parent/> </service>
|
||||
<service name="CPU"> <parent/> </service>
|
||||
<service name="ROM"> <parent/> </service>
|
||||
</route>
|
||||
</start>
|
||||
|
||||
<start name="acpi_drv" caps="250">
|
||||
<resource name="RAM" quantum="4M"/>
|
||||
<route>
|
||||
@@ -28,33 +46,27 @@
|
||||
</route>
|
||||
</start>
|
||||
|
||||
<start name="report_rom" caps="70">
|
||||
<start name="pci_decode" caps="350">
|
||||
<resource name="RAM" quantum="1M"/>
|
||||
<provides>
|
||||
<service name="ROM" />
|
||||
<service name="Report" />
|
||||
</provides>
|
||||
<config>
|
||||
<policy label="platform_drv -> acpi" report="acpi_drv -> acpi"/>
|
||||
</config>
|
||||
<route>
|
||||
<service name="LOG"> <parent/> </service>
|
||||
<service name="PD"> <parent/> </service>
|
||||
<service name="CPU"> <parent/> </service>
|
||||
<service name="ROM"> <parent/> </service>
|
||||
<service name="Report">
|
||||
<child name="report_rom"/> </service>
|
||||
<service name="ROM" label="system">
|
||||
<child name="report_rom"/> </service>
|
||||
<service name="IO_MEM"> <parent/> </service>
|
||||
<service name="LOG"> <parent/> </service>
|
||||
<service name="PD"> <parent/> </service>
|
||||
<service name="RM"> <parent/> </service>
|
||||
<service name="CPU"> <parent/> </service>
|
||||
<service name="ROM"> <parent/> </service>
|
||||
</route>
|
||||
</start>
|
||||
|
||||
<start name="platform_drv" caps="200" managing_system="yes">
|
||||
<binary name="legacy_pc_platform_drv"/>
|
||||
<resource name="RAM" quantum="3M"/>
|
||||
<provides>
|
||||
<service name="Platform"/>
|
||||
<service name="Acpi"/>
|
||||
</provides>
|
||||
<start name="platform_drv" caps="100" managing_system="yes">
|
||||
<resource name="RAM" quantum="1M"/>
|
||||
<provides> <service name="Platform"/> </provides>
|
||||
<route>
|
||||
<service name="ROM" label="system"> <child name="report_rom"/> </service>
|
||||
<service name="ROM" label="acpi"> <child name="report_rom"/> </service>
|
||||
<service name="ROM" label="devices"> <child name="report_rom"/> </service>
|
||||
<service name="IRQ"> <parent/> </service>
|
||||
<service name="IO_MEM"> <parent/> </service>
|
||||
<service name="IO_PORT"> <parent/> </service>
|
||||
@@ -65,11 +77,11 @@
|
||||
<service name="Timer"> <parent/> </service>
|
||||
</route>
|
||||
<config>
|
||||
<policy label_prefix="usb_drv"> <pci class="USB"/> </policy>
|
||||
<policy label_prefix="usb_drv" info="yes"> <pci class="USB"/> </policy>
|
||||
</config>
|
||||
</start>
|
||||
|
||||
<start name="usb_drv" caps="150">
|
||||
<start name="usb_drv" caps="200">
|
||||
<binary name="pc_usb_host_drv"/>
|
||||
<resource name="RAM" quantum="16M"/>
|
||||
<provides> <service name="Usb"/> </provides>
|
||||
|
||||
@@ -19,6 +19,9 @@ set use_top 0
|
||||
|
||||
set build_components {
|
||||
core init timer
|
||||
drivers/acpi
|
||||
drivers/platform
|
||||
app/pci_decode
|
||||
drivers/framebuffer/intel/pc
|
||||
test/framebuffer
|
||||
server/report_rom
|
||||
@@ -31,9 +34,6 @@ set build_components {
|
||||
append_if $use_gpu build_components { drivers/gpu/intel }
|
||||
append_if $use_top build_components { app/top }
|
||||
|
||||
source ${genode_dir}/repos/base/run/platform_drv.inc
|
||||
append_platform_drv_build_components
|
||||
|
||||
build $build_components
|
||||
|
||||
create_boot_directory
|
||||
@@ -58,22 +58,86 @@ append config {
|
||||
<default-route>
|
||||
<any-service> <parent/> <any-child/> </any-service>
|
||||
</default-route>
|
||||
<default caps="100"/>}
|
||||
<default caps="100"/>
|
||||
|
||||
append_platform_drv_config
|
||||
<start name="report_rom" caps="70">
|
||||
<resource name="RAM" quantum="1M"/>
|
||||
<provides>
|
||||
<service name="ROM" />
|
||||
<service name="Report" />
|
||||
</provides>
|
||||
<config>
|
||||
<policy label="pci_decode -> system" report="acpi_drv -> acpi"/>
|
||||
<policy label="intel_fb_drv -> intel_opregion" report="acpi_drv -> intel_opregion"/>
|
||||
<policy label="platform_drv -> devices" report="pci_decode -> devices"/>
|
||||
</config>
|
||||
<route>
|
||||
<service name="LOG"> <parent/> </service>
|
||||
<service name="PD"> <parent/> </service>
|
||||
<service name="CPU"> <parent/> </service>
|
||||
<service name="ROM"> <parent/> </service>
|
||||
</route>
|
||||
</start>
|
||||
|
||||
<start name="acpi_drv" caps="250">
|
||||
<resource name="RAM" quantum="4M"/>
|
||||
<route>
|
||||
<service name="IO_MEM"> <parent/> </service>
|
||||
<service name="LOG"> <parent/> </service>
|
||||
<service name="PD"> <parent/> </service>
|
||||
<service name="RM"> <parent/> </service>
|
||||
<service name="CPU"> <parent/> </service>
|
||||
<service name="ROM"> <parent/> </service>
|
||||
<service name="Report"> <child name="report_rom"/> </service>
|
||||
</route>
|
||||
</start>
|
||||
|
||||
<start name="pci_decode" caps="350">
|
||||
<resource name="RAM" quantum="1M"/>
|
||||
<route>
|
||||
<service name="Report">
|
||||
<child name="report_rom"/> </service>
|
||||
<service name="ROM" label="system">
|
||||
<child name="report_rom"/> </service>
|
||||
<service name="IO_MEM"> <parent/> </service>
|
||||
<service name="LOG"> <parent/> </service>
|
||||
<service name="PD"> <parent/> </service>
|
||||
<service name="RM"> <parent/> </service>
|
||||
<service name="CPU"> <parent/> </service>
|
||||
<service name="ROM"> <parent/> </service>
|
||||
</route>
|
||||
</start>
|
||||
|
||||
<start name="platform_drv" caps="100" managing_system="yes">
|
||||
<resource name="RAM" quantum="1M"/>
|
||||
<provides> <service name="Platform"/> </provides>
|
||||
<route>
|
||||
<service name="ROM" label="devices"> <child name="report_rom"/> </service>
|
||||
<service name="IRQ"> <parent/> </service>
|
||||
<service name="IO_MEM"> <parent/> </service>
|
||||
<service name="IO_PORT"> <parent/> </service>
|
||||
<service name="ROM"> <parent/> </service>
|
||||
<service name="PD"> <parent/> </service>
|
||||
<service name="CPU"> <parent/> </service>
|
||||
<service name="LOG"> <parent/> </service>
|
||||
</route>
|
||||
<config>
|
||||
<policy label_prefix="intel_fb_drv" info="yes">
|
||||
<pci class="VGA"/>
|
||||
<pci class="ISABRIDGE"/>
|
||||
</policy>
|
||||
<policy label_prefix="intel_gpu_drv" info="yes">
|
||||
<pci class="VGA"/>
|
||||
<pci class="ISABRIDGE"/>
|
||||
</policy>
|
||||
</config>
|
||||
</start>
|
||||
|
||||
append config {
|
||||
<start name="timer">
|
||||
<resource name="RAM" quantum="1M"/>
|
||||
<provides><service name="Timer"/></provides>
|
||||
</start>
|
||||
|
||||
<start name="report_rom" priority="0">
|
||||
<resource name="RAM" quantum="2M"/>
|
||||
<provides> <service name="Report" /> <service name="ROM" /> </provides>
|
||||
<config verbose="no"/>
|
||||
</start>
|
||||
|
||||
<start name="init_dynamic" caps="10000">
|
||||
<binary name="init"/>
|
||||
<resource name="RAM" quantum="1000M"/>
|
||||
@@ -81,7 +145,7 @@ append config {
|
||||
<service name="Report"> <child name="report_rom"/> </service>
|
||||
<service name="Platform"> <child name="platform_drv" label="intel_fb_drv"/> </service>
|
||||
<service name="ROM" label="intel_fb_drv -> intel_opregion">
|
||||
<child name="acpi_report_rom" label="intel_fb_drv -> intel_opregion"/>
|
||||
<child name="report_rom" label="intel_fb_drv -> intel_opregion"/>
|
||||
</service>
|
||||
<any-service> <parent/> <any-child/> </any-service>
|
||||
</route>
|
||||
@@ -221,13 +285,12 @@ install_config $config
|
||||
set boot_modules {
|
||||
core ld.lib.so init timer pc_intel_fb_drv intel_fb_controller
|
||||
test-framebuffer report_rom fs_rom vfs vfs.lib.so vfs_import.lib.so
|
||||
platform_drv acpi_drv pci_decode
|
||||
}
|
||||
|
||||
append_if $use_gpu boot_modules { intel_gpu_drv }
|
||||
append_if $use_top boot_modules { top }
|
||||
|
||||
append_platform_drv_boot_modules
|
||||
|
||||
build_boot_image $boot_modules
|
||||
|
||||
if { [get_cmd_switch --autopilot] } {
|
||||
|
||||
@@ -65,6 +65,9 @@ assert_spec x86
|
||||
|
||||
set build_components {
|
||||
core init timer
|
||||
app/pci_decode
|
||||
drivers/acpi
|
||||
drivers/platform
|
||||
drivers/rtc
|
||||
drivers/wifi/pc
|
||||
server/report_rom
|
||||
@@ -76,9 +79,6 @@ set build_components {
|
||||
lib/vfs_lwip
|
||||
}
|
||||
|
||||
source ${genode_dir}/repos/base/run/platform_drv.inc
|
||||
append_platform_drv_build_components
|
||||
|
||||
build $build_components
|
||||
|
||||
create_boot_directory
|
||||
@@ -108,6 +108,73 @@ append config {
|
||||
<provides> <service name="Timer"/> </provides>
|
||||
</start>
|
||||
|
||||
<start name="report_rom" caps="70">
|
||||
<resource name="RAM" quantum="1M"/>
|
||||
<provides>
|
||||
<service name="ROM" />
|
||||
<service name="Report" />
|
||||
</provides>
|
||||
<config verbose="yes">
|
||||
<policy label="pci_decode -> system" report="acpi_drv -> acpi"/>
|
||||
<policy label="platform_drv -> devices" report="pci_decode -> devices"/>
|
||||
</config>
|
||||
<route>
|
||||
<service name="LOG"> <parent/> </service>
|
||||
<service name="PD"> <parent/> </service>
|
||||
<service name="CPU"> <parent/> </service>
|
||||
<service name="ROM"> <parent/> </service>
|
||||
</route>
|
||||
</start>
|
||||
|
||||
<start name="acpi_drv" caps="250">
|
||||
<resource name="RAM" quantum="4M"/>
|
||||
<route>
|
||||
<service name="IO_MEM"> <parent/> </service>
|
||||
<service name="LOG"> <parent/> </service>
|
||||
<service name="PD"> <parent/> </service>
|
||||
<service name="RM"> <parent/> </service>
|
||||
<service name="CPU"> <parent/> </service>
|
||||
<service name="ROM"> <parent/> </service>
|
||||
<service name="Report"> <child name="report_rom"/> </service>
|
||||
</route>
|
||||
</start>
|
||||
|
||||
<start name="pci_decode" caps="350">
|
||||
<resource name="RAM" quantum="1M"/>
|
||||
<route>
|
||||
<service name="Report">
|
||||
<child name="report_rom"/> </service>
|
||||
<service name="ROM" label="system">
|
||||
<child name="report_rom"/> </service>
|
||||
<service name="IO_MEM"> <parent/> </service>
|
||||
<service name="LOG"> <parent/> </service>
|
||||
<service name="PD"> <parent/> </service>
|
||||
<service name="RM"> <parent/> </service>
|
||||
<service name="CPU"> <parent/> </service>
|
||||
<service name="ROM"> <parent/> </service>
|
||||
</route>
|
||||
</start>
|
||||
|
||||
<start name="platform_drv" caps="100" managing_system="yes">
|
||||
<resource name="RAM" quantum="1M"/>
|
||||
<provides> <service name="Platform"/> </provides>
|
||||
<route>
|
||||
<service name="ROM" label="devices"> <child name="report_rom"/> </service>
|
||||
<service name="IRQ"> <parent/> </service>
|
||||
<service name="IO_MEM"> <parent/> </service>
|
||||
<service name="IO_PORT"> <parent/> </service>
|
||||
<service name="ROM"> <parent/> </service>
|
||||
<service name="PD"> <parent/> </service>
|
||||
<service name="CPU"> <parent/> </service>
|
||||
<service name="LOG"> <parent/> </service>
|
||||
</route>
|
||||
<config>
|
||||
<policy label_prefix="wifi_drv" info="yes">
|
||||
<pci class="WIFI"/>
|
||||
</policy>
|
||||
</config>
|
||||
</start>
|
||||
|
||||
<start name="rtc_drv">
|
||||
<resource name="RAM" quantum="1M"/>
|
||||
<provides> <service name="Rtc"/> </provides>
|
||||
@@ -227,11 +294,6 @@ append config {
|
||||
<any-service> <parent/> <any-child/> </any-service>
|
||||
</route>
|
||||
</start>
|
||||
}
|
||||
|
||||
append_platform_drv_config
|
||||
|
||||
append config {
|
||||
</config>
|
||||
}
|
||||
|
||||
@@ -267,15 +329,13 @@ set boot_modules {
|
||||
wpa_driver_nl80211.lib.so wpa_supplicant.lib.so
|
||||
pc_wifi_drv wifi.lib.so vfs_wifi.lib.so
|
||||
nic_router
|
||||
|
||||
platform_drv acpi_drv pci_decode
|
||||
test-lwip_httpsrv
|
||||
vfs_lwip.lib.so
|
||||
}
|
||||
|
||||
append boot_modules $firmware_modules
|
||||
|
||||
append_platform_drv_boot_modules
|
||||
|
||||
build_boot_image $boot_modules
|
||||
|
||||
run_genode_until forever
|
||||
|
||||
@@ -547,3 +547,33 @@ int wbinvd_on_all_cpus(void)
|
||||
lx_emul_trace(__func__);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
void srcu_drive_gp(struct work_struct *wp);
|
||||
void srcu_drive_gp(struct work_struct *wp)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
int pci_bus_read_config_byte(struct pci_bus *bus, unsigned int devfn,
|
||||
int where, u8 *val)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
int pci_bus_read_config_word(struct pci_bus *bus, unsigned int devfn,
|
||||
int where, u16 *val)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
int pci_bus_write_config_byte(struct pci_bus *bus, unsigned int devfn,
|
||||
int where, u8 val)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
@@ -29,3 +29,22 @@ void emul_free_shmem_file_buffer(void *addr)
|
||||
{
|
||||
Lx_kit::env().memory.free_buffer(addr);
|
||||
}
|
||||
|
||||
|
||||
unsigned short emul_intel_gmch_control_reg()
|
||||
{
|
||||
using namespace Genode;
|
||||
|
||||
unsigned short ret = 0;
|
||||
Lx_kit::env().devices.with_xml([&] (Xml_node node) {
|
||||
node.for_each_sub_node("device", [&] (Xml_node node) {
|
||||
node.for_each_sub_node("pci-config", [&] (Xml_node node) {
|
||||
unsigned short gmch =
|
||||
node.attribute_value<unsigned short>("intel_gmch_control", 0U);
|
||||
if (gmch) ret = gmch;
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* \brief Dummy definitions of Linux Kernel functions
|
||||
* \author Automatically generated file - do no edit
|
||||
* \date 2022-06-24
|
||||
* \date 2022-07-28
|
||||
*/
|
||||
|
||||
#include <lx_emul.h>
|
||||
@@ -1525,14 +1525,6 @@ void mark_page_accessed(struct page * page)
|
||||
}
|
||||
|
||||
|
||||
#include <linux/kernel.h>
|
||||
|
||||
unsigned long long memparse(const char * ptr,char ** retptr)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/io.h>
|
||||
|
||||
void memunmap(void * addr)
|
||||
@@ -1646,7 +1638,7 @@ enum reboot_mode panic_reboot_mode;
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
void pci_assign_unassigned_bridge_resources(struct pci_dev * bridge)
|
||||
int pci_dev_present(const struct pci_device_id * ids)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -1654,14 +1646,7 @@ void pci_assign_unassigned_bridge_resources(struct pci_dev * bridge)
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
void pci_assign_unassigned_bus_resources(struct pci_bus * bus)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern unsigned long pci_cardbus_resource_alignment(struct resource * res);
|
||||
unsigned long pci_cardbus_resource_alignment(struct resource * res)
|
||||
void pci_disable_device(struct pci_dev * dev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -1669,11 +1654,7 @@ unsigned long pci_cardbus_resource_alignment(struct resource * res)
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
unsigned int pci_flags;
|
||||
|
||||
|
||||
extern int pci_idt_bus_quirk(struct pci_bus * bus,int devfn,u32 * l,int timeout);
|
||||
int pci_idt_bus_quirk(struct pci_bus * bus,int devfn,u32 * l,int timeout)
|
||||
int pci_read_config_byte(const struct pci_dev * dev,int where,u8 * val)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -1681,28 +1662,7 @@ int pci_idt_bus_quirk(struct pci_bus * bus,int devfn,u32 * l,int timeout)
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
int pci_mmap_resource_range(struct pci_dev * pdev,int bar,struct vm_area_struct * vma,enum pci_mmap_state mmap_state,int write_combine)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void __init pci_realloc_get_opt(char * str);
|
||||
void __init pci_realloc_get_opt(char * str)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pci_restore_vc_state(struct pci_dev * dev);
|
||||
void pci_restore_vc_state(struct pci_dev * dev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern int pci_save_vc_state(struct pci_dev * dev);
|
||||
int pci_save_vc_state(struct pci_dev * dev)
|
||||
int pci_save_state(struct pci_dev * dev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -1710,42 +1670,23 @@ int pci_save_vc_state(struct pci_dev * dev)
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
void pci_stop_and_remove_bus_device_locked(struct pci_dev * dev)
|
||||
int pci_set_power_state(struct pci_dev * dev,pci_power_t state)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pci_vpd_release(struct pci_dev * dev);
|
||||
void pci_vpd_release(struct pci_dev * dev)
|
||||
#include <linux/pci.h>
|
||||
|
||||
void pci_unmap_rom(struct pci_dev * pdev,void __iomem * rom)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern unsigned int pcibios_assign_all_busses(void);
|
||||
unsigned int pcibios_assign_all_busses(void)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
#include <linux/pci.h>
|
||||
|
||||
|
||||
extern void pcie_aspm_init_link_state(struct pci_dev * pdev);
|
||||
void pcie_aspm_init_link_state(struct pci_dev * pdev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pcie_aspm_pm_state_change(struct pci_dev * pdev);
|
||||
void pcie_aspm_pm_state_change(struct pci_dev * pdev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pcie_aspm_powersave_config_link(struct pci_dev * pdev);
|
||||
void pcie_aspm_powersave_config_link(struct pci_dev * pdev)
|
||||
int pci_write_config_byte(const struct pci_dev * dev,int where,u8 val)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -1789,14 +1730,6 @@ void put_pid(struct pid * pid)
|
||||
}
|
||||
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
int raw_pci_read(unsigned int domain,unsigned int bus,unsigned int devfn,int reg,int len,u32 * val)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/reboot.h>
|
||||
|
||||
enum reboot_mode reboot_mode;
|
||||
@@ -1899,7 +1832,7 @@ void * skb_put(struct sk_buff * skb,unsigned int len)
|
||||
|
||||
#include <linux/smp.h>
|
||||
|
||||
int smp_call_function_single(int cpu,void (* func)(void * info),void * info,int wait)
|
||||
int smp_call_function_single(int cpu,smp_call_func_t func,void * info,int wait)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -2016,3 +1949,4 @@ void wake_q_add_safe(struct wake_q_head * head,struct task_struct * task)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
@@ -28,21 +28,16 @@ struct dma_fence_work_ops;
|
||||
|
||||
void lx_emul_time_udelay(unsigned long usec);
|
||||
|
||||
/* shadow/asm/io.h */
|
||||
void lx_emul_io_port_outb(unsigned char value, unsigned short port);
|
||||
void lx_emul_io_port_outw(unsigned short value, unsigned short port);
|
||||
void lx_emul_io_port_outl(unsigned int value, unsigned short port);
|
||||
|
||||
unsigned char lx_emul_io_port_inb(unsigned short port);
|
||||
unsigned short lx_emul_io_port_inw(unsigned short port);
|
||||
unsigned int lx_emul_io_port_inl(unsigned short port);
|
||||
|
||||
void *emul_alloc_shmem_file_buffer(unsigned long);
|
||||
|
||||
void * intel_io_mem_map(unsigned long offset, unsigned long size);
|
||||
|
||||
#include "lx_i915.h"
|
||||
|
||||
unsigned short emul_intel_gmch_control_reg(void);
|
||||
|
||||
enum { OPREGION_PSEUDO_PHYS_ADDR = 0xffffefff };
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -1,20 +0,0 @@
|
||||
/*
|
||||
* \brief Misc
|
||||
* \author Josef Soentgen
|
||||
* \date 2022-01-20
|
||||
*/
|
||||
|
||||
/*
|
||||
* Copyright (C) 2022 Genode Labs GmbH
|
||||
*
|
||||
* This file is distributed under the terms of the GNU General Public License
|
||||
* version 2.
|
||||
*/
|
||||
|
||||
/* Genode includes */
|
||||
#include <os/backtrace.h>
|
||||
|
||||
extern "C" void lx_backtrace(void)
|
||||
{
|
||||
Genode::backtrace();
|
||||
}
|
||||
@@ -21,6 +21,7 @@
|
||||
#include <rm_session/connection.h>
|
||||
#include <rom_session/connection.h>
|
||||
|
||||
#include <lx_emul.h>
|
||||
|
||||
extern "C" void * intel_io_mem_map(unsigned long const phys,
|
||||
unsigned long const size)
|
||||
@@ -51,12 +52,16 @@ extern "C" void * intel_io_mem_map(unsigned long const phys,
|
||||
}
|
||||
}
|
||||
|
||||
if ((opregion_start <= phys) &&
|
||||
(phys + size <= opregion_start + opregion_size)) {
|
||||
/*
|
||||
* we have to substract the pseudo physical address
|
||||
* we returned when reading the ASLS from config space
|
||||
*/
|
||||
addr_t offset = phys - OPREGION_PSEUDO_PHYS_ADDR;
|
||||
if ((offset + size) <= opregion_size) {
|
||||
|
||||
try {
|
||||
auto ptr = ((addr_t)rom_opregion->local_addr<void>())
|
||||
+ (phys - opregion_start) + (phys & 0xffful);
|
||||
+ offset + (opregion_start & 0xffful);
|
||||
return (void *)ptr;
|
||||
} catch (...) {
|
||||
error("Intel opregion lookup failed");
|
||||
|
||||
140
repos/pc/src/drivers/framebuffer/intel/pc/pci.c
Normal file
140
repos/pc/src/drivers/framebuffer/intel/pc/pci.c
Normal file
@@ -0,0 +1,140 @@
|
||||
/*
|
||||
* \brief Additional PCI functions needed by Intel graphics driver
|
||||
* \author Stefan Kalkowski
|
||||
* \author Josef Soentgen
|
||||
* \date 2022-07-27
|
||||
*/
|
||||
|
||||
/*
|
||||
* Copyright (C) 2022 Genode Labs GmbH
|
||||
*
|
||||
* This file is distributed under the terms of the GNU General Public License
|
||||
* version 2.
|
||||
*/
|
||||
|
||||
#include <lx_emul.h>
|
||||
#include <lx_emul/io_mem.h>
|
||||
#include <lx_emul/pci.h>
|
||||
|
||||
#include <linux/pci.h>
|
||||
#include <drm/i915_drm.h>
|
||||
#include <../drivers/gpu/drm/i915/i915_reg.h>
|
||||
#undef GFX_FLSH_CNTL /* suppress warning of double define */
|
||||
#include <../drivers/char/agp/intel-agp.h>
|
||||
|
||||
|
||||
unsigned long pci_mem_start = 0xaeedbabe;
|
||||
|
||||
|
||||
int pci_bus_alloc_resource(struct pci_bus *bus, struct resource *res,
|
||||
resource_size_t size, resource_size_t align,
|
||||
resource_size_t min, unsigned long type_mask,
|
||||
resource_size_t (*alignf)(void *,
|
||||
const struct resource *,
|
||||
resource_size_t,
|
||||
resource_size_t),
|
||||
void *alignf_data)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
||||
void __iomem *pci_iomap(struct pci_dev *dev, int bar, unsigned long maxlen)
|
||||
{
|
||||
struct resource *r;
|
||||
unsigned long phys_addr;
|
||||
unsigned long size;
|
||||
|
||||
if (!dev || bar > 5) {
|
||||
printk("%s:%d: invalid request for dev: %p bar: %d\n",
|
||||
__func__, __LINE__, dev, bar);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
printk("pci_iomap: request for dev: %s bar: %d\n", dev_name(&dev->dev), bar);
|
||||
|
||||
r = &dev->resource[bar];
|
||||
|
||||
phys_addr = r->start;
|
||||
size = r->end - r->start;
|
||||
|
||||
if (!phys_addr || !size)
|
||||
return NULL;
|
||||
|
||||
return lx_emul_io_mem_map(phys_addr, size);
|
||||
}
|
||||
|
||||
|
||||
void __iomem * pci_map_rom(struct pci_dev * pdev,size_t * size)
|
||||
{
|
||||
/*
|
||||
* Needed for VBT access which we do not allow
|
||||
*/
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
int pci_read_config_word(const struct pci_dev * dev, int where, u16 *val)
|
||||
{
|
||||
switch (where) {
|
||||
/* Intel graphics and memory controller hub control register */
|
||||
/* I830_GMCH_CTRL is identical to INTEL_GMCH_CTRL */
|
||||
case SNB_GMCH_CTRL:
|
||||
case INTEL_GMCH_CTRL:
|
||||
*val = emul_intel_gmch_control_reg();
|
||||
return 0;
|
||||
case SWSCI: /* intel_fb: software smi sci */
|
||||
*val = 0;
|
||||
return 0;
|
||||
};
|
||||
|
||||
printk("%s: %s %d %d\n", __func__, dev_name(&dev->dev), dev->devfn, where);
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
int pci_read_config_dword(const struct pci_dev * dev, int where, u32 *val)
|
||||
{
|
||||
switch (where) {
|
||||
case MCHBAR_I915:
|
||||
case MCHBAR_I965:
|
||||
*val = 0x1; /* return ENABLE bit being set */
|
||||
return 0;
|
||||
case I965_IFPADDR: /* intel host bridge flush page (lower) */
|
||||
case I965_IFPADDR + 4: /* intel host bridge flush page (higher) */
|
||||
*val = 0;
|
||||
return 0;
|
||||
case ASLS:
|
||||
/*
|
||||
* we just use a physical address as token here,
|
||||
* hopefully it never crashes with other I/O memory addresses
|
||||
*/
|
||||
*val = OPREGION_PSEUDO_PHYS_ADDR;
|
||||
return 0;
|
||||
};
|
||||
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
int pci_write_config_word(const struct pci_dev * dev, int where, u16 val)
|
||||
{
|
||||
switch (where) {
|
||||
case SWSCI: /* intel_fb: software smi sci */
|
||||
/* just ignore */
|
||||
return 0;
|
||||
};
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
int pci_write_config_dword(const struct pci_dev * dev, int where, u32 val)
|
||||
{
|
||||
switch (where) {
|
||||
case I965_IFPADDR: /* intel host bridge flush page (lower) */
|
||||
case I965_IFPADDR + 4: /* intel host bridge flush page (higher) */
|
||||
/* just ignore */
|
||||
return 0;
|
||||
};
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -1,5 +1,4 @@
|
||||
arch/x86/lib/hweight.S
|
||||
arch/x86/pci/legacy.c
|
||||
arch/x86/platform/intel/iosf_mbi.c
|
||||
drivers/base/bus.c
|
||||
drivers/base/class.c
|
||||
@@ -183,19 +182,7 @@ drivers/i2c/algos/i2c-algo-bit.c
|
||||
drivers/i2c/i2c-boardinfo.c
|
||||
drivers/i2c/i2c-core-acpi.c
|
||||
drivers/i2c/i2c-core-base.c
|
||||
drivers/pci/access.c
|
||||
drivers/pci/bus.c
|
||||
drivers/pci/host-bridge.c
|
||||
drivers/pci/msi.c
|
||||
drivers/pci/pci-driver.c
|
||||
drivers/pci/pci-label.c
|
||||
drivers/pci/pci-sysfs.c
|
||||
drivers/pci/pci.c
|
||||
drivers/pci/probe.c
|
||||
drivers/pci/rom.c
|
||||
drivers/pci/search.c
|
||||
drivers/pci/setup-res.c
|
||||
drivers/pci/slot.c
|
||||
drivers/video/backlight/backlight.c
|
||||
drivers/video/fbdev/core/fb_notify.c
|
||||
drivers/video/fbdev/core/fbcmap.c
|
||||
@@ -257,7 +244,6 @@ lib/kstrtox.c
|
||||
lib/list_sort.c
|
||||
lib/llist.c
|
||||
lib/math/div64.c
|
||||
lib/pci_iomap.c
|
||||
lib/radix-tree.c
|
||||
lib/rbtree.c
|
||||
lib/refcount.c
|
||||
|
||||
@@ -2,7 +2,6 @@ arch/x86/lib/hweight.S
|
||||
arch/x86/lib/memcpy_64.S
|
||||
arch/x86/lib/memmove_64.S
|
||||
arch/x86/lib/memset_64.S
|
||||
arch/x86/pci/legacy.c
|
||||
arch/x86/platform/intel/iosf_mbi.c
|
||||
drivers/base/bus.c
|
||||
drivers/base/class.c
|
||||
@@ -186,19 +185,7 @@ drivers/i2c/algos/i2c-algo-bit.c
|
||||
drivers/i2c/i2c-boardinfo.c
|
||||
drivers/i2c/i2c-core-acpi.c
|
||||
drivers/i2c/i2c-core-base.c
|
||||
drivers/pci/access.c
|
||||
drivers/pci/bus.c
|
||||
drivers/pci/host-bridge.c
|
||||
drivers/pci/msi.c
|
||||
drivers/pci/pci-driver.c
|
||||
drivers/pci/pci-label.c
|
||||
drivers/pci/pci-sysfs.c
|
||||
drivers/pci/pci.c
|
||||
drivers/pci/probe.c
|
||||
drivers/pci/rom.c
|
||||
drivers/pci/search.c
|
||||
drivers/pci/setup-res.c
|
||||
drivers/pci/slot.c
|
||||
drivers/video/backlight/backlight.c
|
||||
drivers/video/fbdev/core/fb_notify.c
|
||||
drivers/video/fbdev/core/fbcmap.c
|
||||
@@ -259,7 +246,6 @@ lib/kobject_uevent.c
|
||||
lib/kstrtox.c
|
||||
lib/list_sort.c
|
||||
lib/llist.c
|
||||
lib/pci_iomap.c
|
||||
lib/radix-tree.c
|
||||
lib/rbtree.c
|
||||
lib/refcount.c
|
||||
|
||||
@@ -9,21 +9,21 @@ INC_DIR += $(REL_PRG_DIR)
|
||||
INC_DIR += $(REL_PRG_DIR)/shadow
|
||||
|
||||
SRC_CC += main.cc
|
||||
SRC_CC += misc.cc
|
||||
SRC_CC += emul.cc
|
||||
SRC_CC += time.cc
|
||||
SRC_CC += opregion_io_mem.cc
|
||||
SRC_C += dummies.c
|
||||
SRC_C += pci.c
|
||||
SRC_C += lx_emul.c
|
||||
SRC_C += $(notdir $(wildcard $(REL_PRG_DIR)/generated_dummies.c))
|
||||
SRC_C += fb.c
|
||||
SRC_C += lx_user.c
|
||||
SRC_C += gem.c
|
||||
SRC_C += lx_emul/common_dummies.c
|
||||
SRC_C += lx_emul/spec/x86/pci.c
|
||||
SRC_C += lx_emul/shadow/mm/page_alloc.c
|
||||
SRC_C += lx_emul/shadow/drivers/char/random.c
|
||||
|
||||
vpath %.c $(REL_PRG_DIR)
|
||||
vpath %.c $(REL_PRG_DIR)
|
||||
vpath %.cc $(REL_PRG_DIR)
|
||||
|
||||
vpath %.c $(REP_DIR)/src/lib/pc
|
||||
|
||||
@@ -90,3 +90,11 @@ u32 prandom_u32(void)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
void pci_disable_device(struct pci_dev * dev)
|
||||
{
|
||||
lx_emul_trace(__func__);
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* \brief Dummy definitions of Linux Kernel functions
|
||||
* \author Automatically generated file - do no edit
|
||||
* \date 2022-05-06
|
||||
* \date 2022-07-29
|
||||
*/
|
||||
|
||||
#include <lx_emul.h>
|
||||
@@ -301,14 +301,6 @@ int kobject_uevent_env(struct kobject * kobj,enum kobject_action action,char * e
|
||||
}
|
||||
|
||||
|
||||
#include <linux/kernel.h>
|
||||
|
||||
unsigned long long memparse(const char * ptr,char ** retptr)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/irq.h>
|
||||
|
||||
struct irq_chip no_irq_chip;
|
||||
@@ -348,7 +340,7 @@ int param_set_copystring(const char * val,const struct kernel_param * kp)
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
void pci_assign_unassigned_bridge_resources(struct pci_dev * bridge)
|
||||
void pci_clear_mwi(struct pci_dev * dev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -356,14 +348,7 @@ void pci_assign_unassigned_bridge_resources(struct pci_dev * bridge)
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
void pci_assign_unassigned_bus_resources(struct pci_bus * bus)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern unsigned long pci_cardbus_resource_alignment(struct resource * res);
|
||||
unsigned long pci_cardbus_resource_alignment(struct resource * res)
|
||||
struct pci_dev * pci_get_slot(struct pci_bus * bus,unsigned int devfn)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -371,11 +356,7 @@ unsigned long pci_cardbus_resource_alignment(struct resource * res)
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
unsigned int pci_flags;
|
||||
|
||||
|
||||
extern int pci_idt_bus_quirk(struct pci_bus * bus,int devfn,u32 * l,int timeout);
|
||||
int pci_idt_bus_quirk(struct pci_bus * bus,int devfn,u32 * l,int timeout)
|
||||
int pci_set_power_state(struct pci_dev * dev,pci_power_t state)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -383,71 +364,7 @@ int pci_idt_bus_quirk(struct pci_bus * bus,int devfn,u32 * l,int timeout)
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
int pci_mmap_resource_range(struct pci_dev * pdev,int bar,struct vm_area_struct * vma,enum pci_mmap_state mmap_state,int write_combine)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void __init pci_realloc_get_opt(char * str);
|
||||
void __init pci_realloc_get_opt(char * str)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pci_restore_vc_state(struct pci_dev * dev);
|
||||
void pci_restore_vc_state(struct pci_dev * dev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern int pci_save_vc_state(struct pci_dev * dev);
|
||||
int pci_save_vc_state(struct pci_dev * dev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
void pci_stop_and_remove_bus_device_locked(struct pci_dev * dev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pci_vpd_release(struct pci_dev * dev);
|
||||
void pci_vpd_release(struct pci_dev * dev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern unsigned int pcibios_assign_all_busses(void);
|
||||
unsigned int pcibios_assign_all_busses(void)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pcie_aspm_init_link_state(struct pci_dev * pdev);
|
||||
void pcie_aspm_init_link_state(struct pci_dev * pdev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pcie_aspm_pm_state_change(struct pci_dev * pdev);
|
||||
void pcie_aspm_pm_state_change(struct pci_dev * pdev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pcie_aspm_powersave_config_link(struct pci_dev * pdev);
|
||||
void pcie_aspm_powersave_config_link(struct pci_dev * pdev)
|
||||
int pci_write_config_dword(const struct pci_dev * dev,int where,u32 val)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -469,14 +386,6 @@ void put_pid(struct pid * pid)
|
||||
}
|
||||
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
int raw_pci_read(unsigned int domain,unsigned int bus,unsigned int devfn,int reg,int len,u32 * val)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/refcount.h>
|
||||
|
||||
bool refcount_dec_not_one(refcount_t * r)
|
||||
@@ -511,7 +420,7 @@ void seq_printf(struct seq_file * m,const char * f,...)
|
||||
|
||||
#include <linux/smp.h>
|
||||
|
||||
int smp_call_function_single(int cpu,void (* func)(void * info),void * info,int wait)
|
||||
int smp_call_function_single(int cpu,smp_call_func_t func,void * info,int wait)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -572,3 +481,4 @@ void wake_q_add_safe(struct wake_q_head * head,struct task_struct * task)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
@@ -12,3 +12,76 @@
|
||||
*/
|
||||
|
||||
#include <lx_emul.h>
|
||||
#include <linux/pci.h>
|
||||
|
||||
void __iomem * pci_ioremap_bar(struct pci_dev * pdev, int bar)
|
||||
{
|
||||
struct resource *res = &pdev->resource[bar];
|
||||
return ioremap(res->start, resource_size(res));
|
||||
}
|
||||
|
||||
|
||||
enum {
|
||||
UHCI_USBLEGSUP = 0xc0,
|
||||
UHCI_USBRES_INTEL = 0xc4,
|
||||
EHCI_SERIAL_BUS_RELEASE = 0x60,
|
||||
EHCI_PORT_WAKE = 0x62,
|
||||
};
|
||||
|
||||
|
||||
int pci_read_config_byte(const struct pci_dev * dev,int where,u8 * val)
|
||||
{
|
||||
switch (where) {
|
||||
case EHCI_SERIAL_BUS_RELEASE:
|
||||
*val = 0x20;
|
||||
return 0;
|
||||
};
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
int pci_read_config_word(const struct pci_dev * dev,int where,u16 * val)
|
||||
{
|
||||
switch (where) {
|
||||
case PCI_COMMAND:
|
||||
*val = 0x7;
|
||||
return 0;
|
||||
case EHCI_PORT_WAKE:
|
||||
*val = 0;
|
||||
return 0;
|
||||
case UHCI_USBLEGSUP:
|
||||
/* force the driver to do a full_reset */
|
||||
*val = 0xffff;
|
||||
return 0;
|
||||
};
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
int pci_read_config_dword(const struct pci_dev * dev,int where,u32 * val)
|
||||
{
|
||||
*val = 0;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
int pci_write_config_byte(const struct pci_dev * dev,int where,u8 val)
|
||||
{
|
||||
switch (where) {
|
||||
case UHCI_USBRES_INTEL:
|
||||
/* do nothing */
|
||||
return 0;
|
||||
}
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
int pci_write_config_word(const struct pci_dev * dev,int where,u16 val)
|
||||
{
|
||||
switch (where) {
|
||||
case UHCI_USBLEGSUP:
|
||||
/* do nothing */
|
||||
return 0;
|
||||
}
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
@@ -24,8 +24,6 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
void lx_backtrace(void);
|
||||
|
||||
void lx_emul_time_udelay(unsigned long usec);
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
arch/x86/lib/hweight.S
|
||||
arch/x86/pci/legacy.c
|
||||
drivers/base/bus.c
|
||||
drivers/base/class.c
|
||||
drivers/base/component.c
|
||||
@@ -10,18 +9,7 @@ drivers/base/driver.c
|
||||
drivers/base/platform.c
|
||||
drivers/base/property.c
|
||||
drivers/clk/clk-devres.c
|
||||
drivers/pci/access.c
|
||||
drivers/pci/bus.c
|
||||
drivers/pci/host-bridge.c
|
||||
drivers/pci/msi.c
|
||||
drivers/pci/pci-driver.c
|
||||
drivers/pci/pci-sysfs.c
|
||||
drivers/pci/pci.c
|
||||
drivers/pci/probe.c
|
||||
drivers/pci/rom.c
|
||||
drivers/pci/search.c
|
||||
drivers/pci/setup-res.c
|
||||
drivers/pci/slot.c
|
||||
drivers/usb/common/common.c
|
||||
drivers/usb/common/debug.c
|
||||
drivers/usb/core/buffer.c
|
||||
@@ -110,7 +98,6 @@ lib/kobject.c
|
||||
lib/kstrtox.c
|
||||
lib/list_sort.c
|
||||
lib/math/div64.c
|
||||
lib/pci_iomap.c
|
||||
lib/radix-tree.c
|
||||
lib/rbtree.c
|
||||
lib/scatterlist.c
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
arch/x86/lib/hweight.S
|
||||
arch/x86/pci/legacy.c
|
||||
drivers/base/bus.c
|
||||
drivers/base/class.c
|
||||
drivers/base/component.c
|
||||
@@ -10,18 +9,7 @@ drivers/base/driver.c
|
||||
drivers/base/platform.c
|
||||
drivers/base/property.c
|
||||
drivers/clk/clk-devres.c
|
||||
drivers/pci/access.c
|
||||
drivers/pci/bus.c
|
||||
drivers/pci/host-bridge.c
|
||||
drivers/pci/msi.c
|
||||
drivers/pci/pci-driver.c
|
||||
drivers/pci/pci-sysfs.c
|
||||
drivers/pci/pci.c
|
||||
drivers/pci/probe.c
|
||||
drivers/pci/rom.c
|
||||
drivers/pci/search.c
|
||||
drivers/pci/setup-res.c
|
||||
drivers/pci/slot.c
|
||||
drivers/usb/common/common.c
|
||||
drivers/usb/common/debug.c
|
||||
drivers/usb/core/buffer.c
|
||||
@@ -109,7 +97,6 @@ lib/klist.c
|
||||
lib/kobject.c
|
||||
lib/kstrtox.c
|
||||
lib/list_sort.c
|
||||
lib/pci_iomap.c
|
||||
lib/radix-tree.c
|
||||
lib/rbtree.c
|
||||
lib/scatterlist.c
|
||||
|
||||
@@ -7,15 +7,14 @@ LIBS := base pc_lx_emul jitterentropy
|
||||
|
||||
INC_DIR += $(REL_PRG_DIR)
|
||||
SRC_CC += main.cc
|
||||
SRC_CC += misc.cc
|
||||
SRC_CC += time.cc
|
||||
SRC_CC += lx_emul/shared_dma_buffer.cc
|
||||
SRC_C += dummies.c
|
||||
SRC_C += lx_emul.c
|
||||
SRC_C += $(notdir $(wildcard $(REL_PRG_DIR)/generated_dummies.c))
|
||||
SRC_C += common_dummies.c
|
||||
SRC_C += lx_emul/spec/x86/pci.c
|
||||
SRC_C += lx_emul/usb.c
|
||||
|
||||
SRC_C += lx_emul/shadow/lib/kobject_uevent.c
|
||||
vpath %.c $(REP_DIR)/src/lib/pc
|
||||
vpath %.cc $(REP_DIR)/src/lib/pc
|
||||
|
||||
@@ -1,22 +0,0 @@
|
||||
/**
|
||||
* \brief PCI fixup calls to execute
|
||||
* \author Josef Soentgen
|
||||
* \date 2022-02-07
|
||||
*/
|
||||
|
||||
/*
|
||||
* Copyright (C) 2022 Genode Labs GmbH
|
||||
*
|
||||
* This file is distributed under the terms of the GNU General Public License
|
||||
* version 2.
|
||||
*/
|
||||
|
||||
#ifndef _LX_EMUL__PCI_FIXUPS_H_
|
||||
#define _LX_EMUL__PCI_FIXUPS_H_
|
||||
|
||||
static const char * lx_emul_pci_final_fixups[] = {
|
||||
"__pci_fixup_final_quirk_usb_early_handoff",
|
||||
"END_OF_PCI_FIXUPS"
|
||||
};
|
||||
|
||||
#endif /* _LX_EMUL__PCI_FIXUPS_H_ */
|
||||
@@ -244,6 +244,39 @@ bool pciehp_is_native(struct pci_dev *bridge)
|
||||
}
|
||||
|
||||
|
||||
void pci_lock_rescan_remove(void)
|
||||
{
|
||||
lx_emul_trace(__func__);
|
||||
}
|
||||
|
||||
|
||||
void pci_unlock_rescan_remove(void)
|
||||
{
|
||||
lx_emul_trace(__func__);
|
||||
}
|
||||
|
||||
|
||||
bool pci_pme_capable(struct pci_dev *dev, pci_power_t state)
|
||||
{
|
||||
lx_emul_trace(__func__);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
int pcie_capability_read_word(struct pci_dev *dev, int pos, u16 *val)
|
||||
{
|
||||
lx_emul_trace(__func__);
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
||||
u16 pci_find_ext_capability(struct pci_dev *dev, int cap)
|
||||
{
|
||||
lx_emul_trace(__func__);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
#include <linux/thermal.h>
|
||||
|
||||
struct thermal_cooling_device *thermal_cooling_device_register(const char *s,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* \brief Dummy definitions of Linux Kernel functions
|
||||
* \author Automatically generated file - do no edit
|
||||
* \date 2022-06-24
|
||||
* \date 2022-07-29
|
||||
*/
|
||||
|
||||
#include <lx_emul.h>
|
||||
@@ -639,14 +639,6 @@ int kobject_synth_uevent(struct kobject * kobj,const char * buf,size_t count)
|
||||
}
|
||||
|
||||
|
||||
#include <linux/kernel.h>
|
||||
|
||||
unsigned long long memparse(const char * ptr,char ** retptr)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/preempt.h>
|
||||
|
||||
void migrate_disable(void)
|
||||
@@ -712,63 +704,7 @@ enum reboot_mode panic_reboot_mode;
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
void pci_assign_unassigned_bridge_resources(struct pci_dev * bridge)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
void pci_assign_unassigned_bus_resources(struct pci_bus * bus)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern unsigned long pci_cardbus_resource_alignment(struct resource * res);
|
||||
unsigned long pci_cardbus_resource_alignment(struct resource * res)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
unsigned int pci_flags;
|
||||
|
||||
|
||||
extern int pci_idt_bus_quirk(struct pci_bus * bus,int devfn,u32 * l,int timeout);
|
||||
int pci_idt_bus_quirk(struct pci_bus * bus,int devfn,u32 * l,int timeout)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
int pci_mmap_resource_range(struct pci_dev * pdev,int bar,struct vm_area_struct * vma,enum pci_mmap_state mmap_state,int write_combine)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void __init pci_realloc_get_opt(char * str);
|
||||
void __init pci_realloc_get_opt(char * str)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pci_restore_vc_state(struct pci_dev * dev);
|
||||
void pci_restore_vc_state(struct pci_dev * dev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern int pci_save_vc_state(struct pci_dev * dev);
|
||||
int pci_save_vc_state(struct pci_dev * dev)
|
||||
int pci_read_config_dword(const struct pci_dev * dev,int where,u32 * val)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -784,42 +720,7 @@ void pci_stop_and_remove_bus_device(struct pci_dev * dev)
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
void pci_stop_and_remove_bus_device_locked(struct pci_dev * dev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pci_vpd_release(struct pci_dev * dev);
|
||||
void pci_vpd_release(struct pci_dev * dev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern unsigned int pcibios_assign_all_busses(void);
|
||||
unsigned int pcibios_assign_all_busses(void)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pcie_aspm_init_link_state(struct pci_dev * pdev);
|
||||
void pcie_aspm_init_link_state(struct pci_dev * pdev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pcie_aspm_pm_state_change(struct pci_dev * pdev);
|
||||
void pcie_aspm_pm_state_change(struct pci_dev * pdev)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
extern void pcie_aspm_powersave_config_link(struct pci_dev * pdev);
|
||||
void pcie_aspm_powersave_config_link(struct pci_dev * pdev)
|
||||
int pci_write_config_word(const struct pci_dev * dev,int where,u16 val)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -889,14 +790,6 @@ void put_unused_fd(unsigned int fd)
|
||||
}
|
||||
|
||||
|
||||
#include <linux/pci.h>
|
||||
|
||||
int raw_pci_read(unsigned int domain,unsigned int bus,unsigned int devfn,int reg,int len,u32 * val)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/reboot.h>
|
||||
|
||||
enum reboot_mode reboot_mode;
|
||||
@@ -1112,7 +1005,7 @@ int sk_reuseport_attach_filter(struct sock_fprog * fprog,struct sock * sk)
|
||||
|
||||
#include <linux/smp.h>
|
||||
|
||||
int smp_call_function_single(int cpu,void (* func)(void * info),void * info,int wait)
|
||||
int smp_call_function_single(int cpu,smp_call_func_t func,void * info,int wait)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
@@ -574,3 +574,33 @@ void kvfree_call_rcu(struct rcu_head * head,rcu_callback_t func)
|
||||
void *ptr = (void *) head - (unsigned long) func;
|
||||
kvfree(ptr);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/pci.h>
|
||||
#include <uapi/linux/pci_regs.h>
|
||||
|
||||
int pci_write_config_byte(const struct pci_dev * dev,int where,u8 val)
|
||||
{
|
||||
enum { PCI_CFG_RETRY_TIMEOUT = 0x41 };
|
||||
|
||||
switch (where) {
|
||||
/*
|
||||
* iwlwifi: "We disable the RETRY_TIMEOUT register (0x41) to keep
|
||||
* PCI Tx retries from interfering with C3 CPU state"
|
||||
*/
|
||||
case PCI_CFG_RETRY_TIMEOUT:
|
||||
return 0;
|
||||
};
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
int pci_read_config_word(const struct pci_dev * dev,int where,u16 * val)
|
||||
{
|
||||
switch (where) {
|
||||
case PCI_COMMAND:
|
||||
*val = PCI_COMMAND_MASTER | PCI_COMMAND_MEMORY | PCI_COMMAND_IO;
|
||||
return 0;
|
||||
};
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
arch/x86/lib/hweight.S
|
||||
arch/x86/pci/legacy.c
|
||||
certs/common.c
|
||||
crypto/acompress.c
|
||||
crypto/aead.c
|
||||
@@ -117,18 +116,7 @@ drivers/net/wireless/intel/iwlwifi/pcie/trans.c
|
||||
drivers/net/wireless/intel/iwlwifi/pcie/tx-gen2.c
|
||||
drivers/net/wireless/intel/iwlwifi/pcie/tx.c
|
||||
drivers/net/wireless/intel/iwlwifi/queue/tx.c
|
||||
drivers/pci/access.c
|
||||
drivers/pci/bus.c
|
||||
drivers/pci/host-bridge.c
|
||||
drivers/pci/msi.c
|
||||
drivers/pci/pci-driver.c
|
||||
drivers/pci/pci-sysfs.c
|
||||
drivers/pci/pci.c
|
||||
drivers/pci/probe.c
|
||||
drivers/pci/rom.c
|
||||
drivers/pci/search.c
|
||||
drivers/pci/setup-res.c
|
||||
drivers/pci/slot.c
|
||||
fs/nls/nls_base.c
|
||||
kernel/irq/chip.c
|
||||
kernel/irq/devres.c
|
||||
@@ -187,7 +175,6 @@ lib/kstrtox.c
|
||||
lib/list_sort.c
|
||||
lib/math/div64.c
|
||||
lib/nlattr.c
|
||||
lib/pci_iomap.c
|
||||
lib/radix-tree.c
|
||||
lib/rbtree.c
|
||||
lib/refcount.c
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
arch/x86/lib/hweight.S
|
||||
arch/x86/pci/legacy.c
|
||||
certs/common.c
|
||||
crypto/acompress.c
|
||||
crypto/aead.c
|
||||
@@ -117,18 +116,7 @@ drivers/net/wireless/intel/iwlwifi/pcie/trans.c
|
||||
drivers/net/wireless/intel/iwlwifi/pcie/tx-gen2.c
|
||||
drivers/net/wireless/intel/iwlwifi/pcie/tx.c
|
||||
drivers/net/wireless/intel/iwlwifi/queue/tx.c
|
||||
drivers/pci/access.c
|
||||
drivers/pci/bus.c
|
||||
drivers/pci/host-bridge.c
|
||||
drivers/pci/msi.c
|
||||
drivers/pci/pci-driver.c
|
||||
drivers/pci/pci-sysfs.c
|
||||
drivers/pci/pci.c
|
||||
drivers/pci/probe.c
|
||||
drivers/pci/rom.c
|
||||
drivers/pci/search.c
|
||||
drivers/pci/setup-res.c
|
||||
drivers/pci/slot.c
|
||||
fs/nls/nls_base.c
|
||||
kernel/irq/chip.c
|
||||
kernel/irq/devres.c
|
||||
@@ -186,7 +174,6 @@ lib/kobject.c
|
||||
lib/kstrtox.c
|
||||
lib/list_sort.c
|
||||
lib/nlattr.c
|
||||
lib/pci_iomap.c
|
||||
lib/radix-tree.c
|
||||
lib/rbtree.c
|
||||
lib/refcount.c
|
||||
|
||||
@@ -40,6 +40,15 @@ int ___ratelimit(struct ratelimit_state * rs, const char * func)
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
#include <linux/sched.h>
|
||||
|
||||
long io_schedule_timeout(long timeout)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
void register_syscore_ops(struct syscore_ops * ops)
|
||||
{
|
||||
lx_emul_trace(__func__);
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*
|
||||
* \brief Dummy definitions of Linux Kernel functions
|
||||
* \author Automatically generated file - do no edit
|
||||
* \date 2022-05-06
|
||||
* \date 2022-09-27
|
||||
*/
|
||||
|
||||
#include <lx_emul.h>
|
||||
@@ -23,6 +23,14 @@ const char * __clk_get_name(const struct clk * clk)
|
||||
}
|
||||
|
||||
|
||||
#include <linux/sched/task.h>
|
||||
|
||||
void __put_task_struct(struct task_struct * tsk)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/srcu.h>
|
||||
|
||||
void __srcu_read_unlock(struct srcu_struct * ssp,int idx)
|
||||
@@ -31,49 +39,9 @@ void __srcu_read_unlock(struct srcu_struct * ssp,int idx)
|
||||
}
|
||||
|
||||
|
||||
#include <linux/printk.h>
|
||||
#include <linux/uaccess.h>
|
||||
|
||||
int printk_deferred(const char * fmt,...)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/irq_work.h>
|
||||
|
||||
void irq_work_tick(void)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/printk.h>
|
||||
|
||||
asmlinkage __visible void dump_stack(void)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/sched.h>
|
||||
|
||||
int io_schedule_prepare(void)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/sched.h>
|
||||
|
||||
void io_schedule_finish(int token)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/sched.h>
|
||||
|
||||
long io_schedule_timeout(long timeout)
|
||||
unsigned long _copy_to_user(void __user * to,const void * from,unsigned long n)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -88,15 +56,47 @@ void ack_bad_irq(unsigned int irq)
|
||||
|
||||
#include <linux/kobject.h>
|
||||
|
||||
int kobject_synth_uevent(struct kobject * kobj,const char * buf,size_t count)
|
||||
int add_uevent_var(struct kobj_uevent_env * env,const char * format,...)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/kobject.h>
|
||||
#include <linux/printk.h>
|
||||
|
||||
int add_uevent_var(struct kobj_uevent_env * env,const char * format,...)
|
||||
asmlinkage __visible void dump_stack(void)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/capability.h>
|
||||
|
||||
bool file_ns_capable(const struct file * file,struct user_namespace * ns,int cap)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/property.h>
|
||||
|
||||
void fwnode_remove_software_node(struct fwnode_handle * fwnode)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/kernel.h>
|
||||
|
||||
int get_option(char ** str,int * pint)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/pseudo_fs.h>
|
||||
|
||||
struct pseudo_fs_context * init_pseudo(struct fs_context * fc,unsigned long magic)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -107,9 +107,36 @@ int add_uevent_var(struct kobj_uevent_env * env,const char * format,...)
|
||||
bool initcall_debug;
|
||||
|
||||
|
||||
#include <linux/irq.h>
|
||||
#include <linux/sched.h>
|
||||
|
||||
struct irq_chip no_irq_chip;
|
||||
void io_schedule_finish(int token)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/sched.h>
|
||||
|
||||
int io_schedule_prepare(void)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/irq_work.h>
|
||||
|
||||
void irq_work_tick(void)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/property.h>
|
||||
|
||||
bool is_software_node(const struct fwnode_handle * fwnode)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/kobject.h>
|
||||
@@ -125,49 +152,30 @@ void kill_anon_super(struct super_block * sb)
|
||||
}
|
||||
|
||||
|
||||
#include <linux/property.h>
|
||||
#include <linux/kobject.h>
|
||||
|
||||
bool is_software_node(const struct fwnode_handle * fwnode)
|
||||
int kobject_synth_uevent(struct kobject * kobj,const char * buf,size_t count)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/property.h>
|
||||
#include <linux/irq.h>
|
||||
|
||||
void fwnode_remove_software_node(struct fwnode_handle * fwnode)
|
||||
struct irq_chip no_irq_chip;
|
||||
|
||||
|
||||
#include <linux/irq.h>
|
||||
|
||||
void note_interrupt(struct irq_desc * desc,irqreturn_t action_ret)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/sched/task.h>
|
||||
#include <linux/printk.h>
|
||||
|
||||
void __put_task_struct(struct task_struct * tsk)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/kernel.h>
|
||||
|
||||
int get_option(char ** str,int * pint)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/sched/wake_q.h>
|
||||
|
||||
void wake_q_add_safe(struct wake_q_head * head,struct task_struct * task)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/capability.h>
|
||||
|
||||
bool file_ns_capable(const struct file * file,struct user_namespace * ns,int cap)
|
||||
int printk_deferred(const char * fmt,...)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -181,25 +189,9 @@ void seq_printf(struct seq_file * m,const char * f,...)
|
||||
}
|
||||
|
||||
|
||||
#include <linux/pseudo_fs.h>
|
||||
|
||||
struct pseudo_fs_context * init_pseudo(struct fs_context * fc,unsigned long magic)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/smp.h>
|
||||
|
||||
int smp_call_function_single(int cpu,void (* func)(void * info),void * info,int wait)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/uaccess.h>
|
||||
|
||||
unsigned long _copy_to_user(void __user * to,const void * from,unsigned long n)
|
||||
int smp_call_function_single(int cpu,smp_call_func_t func,void * info,int wait)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
@@ -216,3 +208,12 @@ int string_escape_mem(const char * src,size_t isz,char * dst,size_t osz,unsigned
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
#include <linux/sched/wake_q.h>
|
||||
|
||||
void wake_q_add_safe(struct wake_q_head * head,struct task_struct * task)
|
||||
{
|
||||
lx_emul_trace_and_stop(__func__);
|
||||
}
|
||||
|
||||
|
||||
@@ -7,6 +7,7 @@ drivers/base/devres.c
|
||||
drivers/base/driver.c
|
||||
drivers/base/platform.c
|
||||
drivers/base/property.c
|
||||
drivers/pci/pci-driver.c
|
||||
kernel/async.c
|
||||
kernel/irq/chip.c
|
||||
kernel/irq/devres.c
|
||||
|
||||
Reference in New Issue
Block a user