pc: consoldiate LX emul of current drivers

This commit de-duplicates the redundant dummy implementations and
to some degree also the 'lx_emul.c' implementations while also
decluttering the various 'dep.list' files.

The code is moved into 'src/lib/pc/lx_emul' where it becomes part
of the 'pc_lx_emul' library.

Fixes #4500.
This commit is contained in:
Josef Söntgen 2022-05-03 18:32:20 +02:00 committed by Christian Helmuth
parent e313059dd5
commit 6954547b4c
54 changed files with 2858 additions and 5716 deletions

View File

@ -31,3 +31,32 @@ SRC_CC += lx_emul/pci_init.cc
SRC_CC += lx_kit/device.cc SRC_CC += lx_kit/device.cc
SRC_CC += lx_kit/memory_dma.cc SRC_CC += lx_kit/memory_dma.cc
SRC_CC += lx_kit/spec/x86/platform.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
SRC_C += lx_emul/shadow/fs/sysfs/group.c
SRC_C += lx_emul/shadow/fs/sysfs/symlink.c
#
# Replacing implementations that could be merged into DDE Linux.
#
SRC_C += lx_emul/mapping.c
SRC_C += lx_emul/page_alloc.c
SRC_C += lx_emul/sched_core.c
SRC_C += lx_emul/slab_common.c
SRC_C += lx_emul/softirq.c
SRC_C += lx_emul/vmalloc.c
SRC_C += lx_emul/shadow/fs/libfs.c
SRC_C += lx_emul/shadow/kernel/rcu/tiny.c
SRC_C += lx_emul/shadow/lib/logic_iomem.c
SRC_C += lx_emul/shadow/drivers/acpi/bus.c
SRC_C += lx_emul/shadow/drivers/acpi/device_sysfs.c
SRC_C += lx_emul/shadow/drivers/acpi/glue.c
SRC_C += lx_emul/shadow/drivers/acpi/property.c
SRC_C += lx_emul/shadow/drivers/acpi/scan.c
SRC_C += lx_emul/shadow/drivers/acpi/utils.c
# not needed by intel fb
SRC_C += lx_emul/shadow/mm/dmapool.c

View File

@ -1 +1 @@
# the a64_lx_emul libray exists only for the import file # the pc_lx_emul libray exists only for the import file

View File

@ -10,10 +10,10 @@ LIBS += base pc_linux_generated pc_lx_emul
INC_DIR := $(TARGET_LIB_DIR) INC_DIR := $(TARGET_LIB_DIR)
SRC_CC += wlan.cc SRC_CC += wlan.cc
SRC_CC += misc.cc SRC_CC += misc.cc
SRC_CC += time.cc
SRC_CC += firmware.cc SRC_CC += firmware.cc
SRC_CC += socket_call.cc SRC_CC += socket_call.cc
SRC_CC += random.cc SRC_CC += random.cc
SRC_CC += time.cc
SRC_C += dummies.c SRC_C += dummies.c
SRC_C += lx_emul.c SRC_C += lx_emul.c
@ -23,7 +23,7 @@ CC_OPT_lx_socket_call += -DKBUILD_MODNAME='"lx_socket_call"'
SRC_C += lx_socket_call.c SRC_C += lx_socket_call.c
SRC_C += $(notdir $(wildcard $(TARGET_LIB_DIR)/generated_dummies.c)) SRC_C += $(notdir $(wildcard $(TARGET_LIB_DIR)/generated_dummies.c))
SRC_C += pc/lx_emul/common_dummies.c SRC_C += lx_emul/common_dummies.c
SRC_C += lx_emul/spec/x86/pci.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)/drivers/net/wireless/intel/iwlwifi
@ -33,9 +33,13 @@ CC_C_OPT += -Wno-address-of-packed-member
#CC_OPT += -DCONFIG_IWLWIFI_DEBUG #CC_OPT += -DCONFIG_IWLWIFI_DEBUG
SRC_C += lx_emul/shadow/lib/kobject_uevent.c
vpath %.c $(REP_DIR)/src/lib/pc
vpath %.cc $(REP_DIR)/src/lib/pc
vpath %.c $(TARGET_LIB_DIR) vpath %.c $(TARGET_LIB_DIR)
vpath %.cc $(TARGET_LIB_DIR) vpath %.cc $(TARGET_LIB_DIR)
vpath pc/lx_emul/common_dummies.c $(REP_DIR)/src/lib
CUSTOM_TARGET_DEPS += $(TARGET_LIB_DIR)/symbol.map CUSTOM_TARGET_DEPS += $(TARGET_LIB_DIR)/symbol.map

View File

@ -1,5 +1,6 @@
MIRROR_FROM_REP_DIR := src/drivers/framebuffer/intel/pc \ MIRROR_FROM_REP_DIR := src/drivers/framebuffer/intel/pc \
src/lib/pc/lx_emul src/lib/pc/lx_emul \
src/include
content: $(MIRROR_FROM_REP_DIR) content: $(MIRROR_FROM_REP_DIR)

View File

@ -1,5 +1,6 @@
MIRROR_FROM_REP_DIR := src/drivers/usb_host/pc \ MIRROR_FROM_REP_DIR := src/drivers/usb_host/pc \
src/lib/pc/lx_emul src/lib/pc/lx_emul \
src/include
MIRROR_FROM_OS_DIR := src/lib/genode_c_api/usb.cc MIRROR_FROM_OS_DIR := src/lib/genode_c_api/usb.cc
content: $(MIRROR_FROM_REP_DIR) $(MIRROR_FROM_OS_DIR) content: $(MIRROR_FROM_REP_DIR) $(MIRROR_FROM_OS_DIR)

View File

@ -7,6 +7,7 @@ LIB_MK := $(addprefix lib/mk/,wifi_firmware.mk wifi.inc vfs_wifi.mk) \
MIRROR_FROM_REP_DIR := src/drivers/wifi/pc \ MIRROR_FROM_REP_DIR := src/drivers/wifi/pc \
src/lib/pc/lx_emul \ src/lib/pc/lx_emul \
src/include \
$(LIB_MK) \ $(LIB_MK) \
$(shell cd $(REP_DIR); find src/drivers/wifi -type f) \ $(shell cd $(REP_DIR); find src/drivers/wifi -type f) \
$(shell cd $(REP_DIR); find src/lib/wifi -type f) \ $(shell cd $(REP_DIR); find src/lib/wifi -type f) \

File diff suppressed because it is too large Load Diff

View File

@ -33,228 +33,11 @@
#include <linux/timekeeper_internal.h> #include <linux/timekeeper_internal.h>
unsigned long init_stack[THREAD_SIZE / sizeof(unsigned long)];
unsigned long lpj_fine = 0;
const guid_t pci_acpi_dsm_guid = const guid_t pci_acpi_dsm_guid =
GUID_INIT(0xe5c937d0, 0x3553, 0x4d7a, GUID_INIT(0xe5c937d0, 0x3553, 0x4d7a,
0x91, 0x17, 0xea, 0x4d, 0x19, 0xc3, 0x43, 0x4d); 0x91, 0x17, 0xea, 0x4d, 0x19, 0xc3, 0x43, 0x4d);
void rcu_barrier(void)
{
lx_emul_trace_and_stop(__func__);
}
int __cpuhp_setup_state(enum cpuhp_state state,const char * name,bool invoke,int (* startup)(unsigned int cpu),int (* teardown)(unsigned int cpu),bool multi_instance)
{
lx_emul_trace(__func__);
return 0;
}
void update_vsyscall(struct timekeeper * tk)
{
lx_emul_trace(__func__);
}
void clocksource_arch_init(struct clocksource * cs)
{
lx_emul_trace(__func__);
}
void ignore_signals(struct task_struct * t)
{
lx_emul_trace(__func__);
}
void calc_global_load(void)
{
lx_emul_trace(__func__);
}
void account_process_tick(struct task_struct * p,int user_tick)
{
lx_emul_trace(__func__);
}
void rcu_sched_clock_irq(int user)
{
lx_emul_trace(__func__);
}
void kernfs_get(struct kernfs_node * kn)
{
lx_emul_trace(__func__);
}
void kernfs_put(struct kernfs_node * kn)
{
lx_emul_trace(__func__);
}
int software_node_notify(struct device * dev,unsigned long action)
{
lx_emul_trace(__func__);
return 0;
}
void get_random_bytes(void * buf,int nbytes)
{
lx_emul_trace(__func__);
}
int __must_check get_random_bytes_arch(void * buf,int nbytes)
{
lx_emul_trace(__func__);
return 0;
}
int add_random_ready_callback(struct random_ready_callback * rdy)
{
lx_emul_trace(__func__);
return 0;
}
void add_interrupt_randomness(int irq,int irq_flags)
{
lx_emul_trace(__func__);
}
int sysfs_create_files(struct kobject * kobj,const struct attribute * const * ptr)
{
lx_emul_trace(__func__);
return 0;
}
int sysfs_create_bin_file(struct kobject * kobj,const struct bin_attribute * attr)
{
lx_emul_trace(__func__);
return 0;
}
void sysfs_remove_file_ns(struct kobject * kobj,const struct attribute * attr,const void * ns)
{
lx_emul_trace(__func__);
}
int sysfs_create_dir_ns(struct kobject * kobj,const void * ns)
{
lx_emul_trace(__func__);
return 0;
}
int sysfs_create_file_ns(struct kobject * kobj,const struct attribute * attr,const void * ns)
{
lx_emul_trace(__func__);
return 0;
}
int sysfs_create_link(struct kobject * kobj,struct kobject * target,const char * name)
{
lx_emul_trace(__func__);
return 0;
}
int sysfs_create_groups(struct kobject * kobj,const struct attribute_group ** groups)
{
lx_emul_trace(__func__);
return 0;
}
void sysfs_remove_link(struct kobject * kobj,const char * name)
{
lx_emul_trace(__func__);
}
void sysfs_remove_groups(struct kobject * kobj,const struct attribute_group ** groups)
{
lx_emul_trace(__func__);
}
void sysfs_remove_dir(struct kobject * kobj)
{
lx_emul_trace(__func__);
}
void sysfs_remove_bin_file(struct kobject * kobj,const struct bin_attribute * attr)
{
lx_emul_trace(__func__);
}
bool sysfs_remove_file_self(struct kobject * kobj,const struct attribute * attr)
{
lx_emul_trace(__func__);
return false;
}
void sysfs_remove_files(struct kobject * kobj,const struct attribute * const * ptr)
{
lx_emul_trace(__func__);
}
void sysfs_delete_link(struct kobject * kobj,struct kobject * targ,const char * name)
{
lx_emul_trace(__func__);
}
int sysfs_emit(char * buf,const char * fmt,...)
{
lx_emul_trace(__func__);
return PAGE_SIZE;
}
int sysfs_emit_at(char * buf, int at, const char * fmt,...)
{
lx_emul_trace(__func__);
return at > PAGE_SIZE ? PAGE_SIZE : PAGE_SIZE - at;
}
void sysfs_notify(struct kobject * kobj,const char * dir,const char * attr)
{
lx_emul_trace(__func__);
}
void intel_engines_add_sysfs(struct drm_i915_private * i915)
{
lx_emul_trace(__func__);
}
void register_syscore_ops(struct syscore_ops * ops) void register_syscore_ops(struct syscore_ops * ops)
{ {
wait_bit_init(); wait_bit_init();
@ -262,64 +45,6 @@ void register_syscore_ops(struct syscore_ops * ops)
} }
void pci_allocate_vc_save_buffers(struct pci_dev * dev)
{
lx_emul_trace(__func__);
}
void pci_vpd_init(struct pci_dev * dev)
{
lx_emul_trace(__func__);
}
int pci_proc_attach_device(struct pci_dev * dev)
{
lx_emul_trace(__func__);
return 0;
}
void i915_pmu_init(void)
{
lx_emul_trace(__func__);
}
void i915_pmu_register(struct drm_i915_private * i915)
{
lx_emul_trace(__func__);
}
bool parse_option_str(const char *str, const char *option)
{
lx_emul_trace(__func__);
return false;
}
int __register_chrdev(unsigned int major,unsigned int baseminor,unsigned int count,const char * name,const struct file_operations * fops)
{
lx_emul_trace(__func__);
return 0;
}
void intel_gt_driver_late_release(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
bool intel_vgpu_active(struct drm_i915_private * dev_priv)
{
lx_emul_trace(__func__);
return false;
}
void unregister_shrinker(struct shrinker * shrinker) void unregister_shrinker(struct shrinker * shrinker)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);
@ -333,21 +58,7 @@ int register_shrinker(struct shrinker * shrinker)
} }
int intel_gt_init_mmio(struct intel_gt * gt) void unregister_handler_proc(unsigned int irq,struct irqaction * action)
{
lx_emul_trace(__func__);
return 0;
}
int __intel_gt_reset(struct intel_gt * gt, intel_engine_mask_t engine_mask)
{
lx_emul_trace(__func__);
return 0;
}
void i915_perf_init(struct drm_i915_private * i915)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);
} }
@ -361,161 +72,85 @@ int drm_aperture_remove_conflicting_pci_framebuffers(struct pci_dev * pdev,
} }
void intel_gt_init_hw_early(struct intel_gt * gt, struct i915_ggtt * ggtt) #include <linux/firmware.h>
void release_firmware(const struct firmware * fw)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);
} }
int intel_gt_probe_lmem(struct intel_gt * gt) #include <linux/firmware.h>
int request_firmware(const struct firmware ** firmware_p,const char * name,struct device * device)
{
lx_emul_trace(__func__);
return -1;
}
#include <linux/firmware.h>
int request_firmware_direct(const struct firmware ** firmware_p,const char * name,struct device * device)
{
lx_emul_trace(__func__);
return -1;
}
int ___ratelimit(struct ratelimit_state * rs, const char * func)
{
/*
* from lib/ratelimit.c:
* " 0 means callbacks will be suppressed.
* 1 means go ahead and do it. "
*/
lx_emul_trace(__func__);
return 1;
}
#include <net/net_namespace.h>
struct net init_net;
#include <linux/skbuff.h>
void kfree_skb(struct sk_buff * skb)
{
if (!skb)
return;
lx_emul_trace(__func__);
printk("%s:%d: leaking skb: %p\n", __func__, __LINE__, skb);
}
#include <net/net_namespace.h>
int register_pernet_subsys(struct pernet_operations * ops)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);
return 0; return 0;
} }
void intel_gt_init_workarounds(struct drm_i915_private * i915) int set_pages_uc(struct page * page,int numpages)
{
lx_emul_trace(__func__);
}
void sched_set_fifo(struct task_struct * p)
{
lx_emul_trace(__func__);
}
void gen8_gt_irq_handler(struct intel_gt * gt,u32 master_ctl)
{
lx_emul_trace(__func__);
}
void gen11_gt_irq_reset(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void gen11_gt_irq_handler(struct intel_gt * gt, const u32 master_ctl)
{
lx_emul_trace(__func__);
}
void gen11_gt_irq_postinstall(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void gen8_gt_irq_reset(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void gen8_gt_irq_postinstall(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void gen5_gt_irq_reset(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void gen5_gt_irq_postinstall(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void register_irq_proc(unsigned int irq,struct irq_desc * desc)
{
lx_emul_trace(__func__);
}
void register_handler_proc(unsigned int irq,struct irqaction * action)
{
lx_emul_trace(__func__);
}
void unregister_handler_proc(unsigned int irq,struct irqaction * action)
{
lx_emul_trace(__func__);
}
void intel_vgpu_register(struct drm_i915_private * i915)
{
lx_emul_trace(__func__);
}
void i915_perf_register(struct drm_i915_private * i915)
{
lx_emul_trace(__func__);
}
void intel_gt_driver_register(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void i915_perf_sysctl_register(void)
{
lx_emul_trace(__func__);
}
int acpi_platform_notify(struct device *dev, enum kobject_action action)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);
return 0; return 0;
} }
bool acpi_driver_match_device(struct device *dev, const struct device_driver *drv) bool irq_work_queue(struct irq_work * work)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);
return false; return false;
} }
bool is_acpi_device_node(const struct fwnode_handle *fwnode) void iomap_free(resource_size_t base, unsigned long size)
{
lx_emul_trace(__func__);
return false;
}
enum dev_dma_attr acpi_get_dma_attr(struct acpi_device *adev)
{
lx_emul_trace_and_stop(__func__);
}
int acpi_dma_configure_id(struct device *dev, enum dev_dma_attr attr, const u32 *input_id)
{
lx_emul_trace_and_stop(__func__);
}
int acpi_device_uevent_modalias(struct device *dev, struct kobj_uevent_env *event)
{
lx_emul_trace_and_stop(__func__);
}
int acpi_device_modalias(struct device *device, char * x, int y)
{ {
lx_emul_trace_and_stop(__func__); lx_emul_trace_and_stop(__func__);
} }
@ -527,19 +162,6 @@ void acpi_video_unregister(void)
} }
bool acpi_check_dsm(acpi_handle handle, const guid_t *guid, u64 rev, u64 funcs)
{
lx_emul_trace_and_stop(__func__);
}
union acpi_object *acpi_evaluate_dsm(acpi_handle handle, const guid_t *guid,
u64 rev, u64 func, union acpi_object *argv4)
{
lx_emul_trace_and_stop(__func__);
}
acpi_status acpi_remove_address_space_handler(acpi_handle device, acpi_status acpi_remove_address_space_handler(acpi_handle device,
acpi_adr_space_type space_id, acpi_adr_space_type space_id,
acpi_adr_space_handler handler) acpi_adr_space_handler handler)
@ -635,13 +257,6 @@ struct irq_domain *pci_host_bridge_acpi_msi_domain(struct pci_bus *bus)
} }
int pci_acpi_program_hp_params(struct pci_dev *dev)
{
lx_emul_trace(__func__);
return 0;
}
int pnp_range_reserved(resource_size_t start, resource_size_t end) int pnp_range_reserved(resource_size_t start, resource_size_t end)
{ {
lx_emul_trace_and_stop(__func__); lx_emul_trace_and_stop(__func__);
@ -675,6 +290,173 @@ raw_copy_from_user(void *to, const void __user * from, unsigned long n)
} }
int register_acpi_notifier(struct notifier_block * nb)
{
lx_emul_trace(__func__);
return 0;
}
int unregister_acpi_notifier(struct notifier_block * nb)
{
lx_emul_trace(__func__);
return 0;
}
int acpi_reconfig_notifier_register(struct notifier_block * nb)
{
lx_emul_trace(__func__);
return 0;
}
/*
* i915 specific dummies follow below.
*/
void intel_engines_add_sysfs(struct drm_i915_private * i915)
{
lx_emul_trace(__func__);
}
void i915_pmu_init(void)
{
lx_emul_trace(__func__);
}
void i915_pmu_register(struct drm_i915_private * i915)
{
lx_emul_trace(__func__);
}
void intel_gt_driver_late_release(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
bool intel_vgpu_active(struct drm_i915_private * dev_priv)
{
lx_emul_trace(__func__);
return false;
}
int intel_gt_init_mmio(struct intel_gt * gt)
{
lx_emul_trace(__func__);
return 0;
}
int __intel_gt_reset(struct intel_gt * gt, intel_engine_mask_t engine_mask)
{
lx_emul_trace(__func__);
return 0;
}
void i915_perf_init(struct drm_i915_private * i915)
{
lx_emul_trace(__func__);
}
void intel_gt_init_hw_early(struct intel_gt * gt, struct i915_ggtt * ggtt)
{
lx_emul_trace(__func__);
}
int intel_gt_probe_lmem(struct intel_gt * gt)
{
lx_emul_trace(__func__);
return 0;
}
void intel_gt_init_workarounds(struct drm_i915_private * i915)
{
lx_emul_trace(__func__);
}
void gen8_gt_irq_handler(struct intel_gt * gt,u32 master_ctl)
{
lx_emul_trace(__func__);
}
void gen11_gt_irq_reset(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void gen11_gt_irq_handler(struct intel_gt * gt, const u32 master_ctl)
{
lx_emul_trace(__func__);
}
void gen11_gt_irq_postinstall(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void gen8_gt_irq_reset(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void gen8_gt_irq_postinstall(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void gen5_gt_irq_reset(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void gen5_gt_irq_postinstall(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void intel_vgpu_register(struct drm_i915_private * i915)
{
lx_emul_trace(__func__);
}
void i915_perf_register(struct drm_i915_private * i915)
{
lx_emul_trace(__func__);
}
void intel_gt_driver_register(struct intel_gt * gt)
{
lx_emul_trace(__func__);
}
void i915_perf_sysctl_register(void)
{
lx_emul_trace(__func__);
}
int i915_gemfs_init(struct drm_i915_private * i915) int i915_gemfs_init(struct drm_i915_private * i915)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);
@ -710,41 +492,6 @@ int __init i915_global_scheduler_init(void)
} }
void pci_fixup_device(enum pci_fixup_pass pass,struct pci_dev * dev)
{
lx_emul_trace(__func__);
}
int pci_dev_specific_reset(struct pci_dev * dev,int probe)
{
lx_emul_trace(__func__);
return 0;
}
int register_acpi_notifier(struct notifier_block * nb)
{
lx_emul_trace(__func__);
return 0;
}
int unregister_acpi_notifier(struct notifier_block * nb)
{
lx_emul_trace(__func__);
return 0;
}
int acpi_reconfig_notifier_register(struct notifier_block * nb)
{
lx_emul_trace(__func__);
return 0;
}
int intel_vgt_balloon(struct i915_ggtt * ggtt) int intel_vgt_balloon(struct i915_ggtt * ggtt)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);
@ -758,96 +505,12 @@ void intel_gt_info_print(const struct intel_gt_info * info,struct drm_printer *
} }
int set_pages_uc(struct page * page,int numpages)
{
lx_emul_trace(__func__);
return 0;
}
bool irq_work_queue(struct irq_work * work)
{
lx_emul_trace(__func__);
return false;
}
void iomap_free(resource_size_t base, unsigned long size)
{
lx_emul_trace_and_stop(__func__);
}
void i915_gem_object_release_mmap_offset(struct drm_i915_gem_object * obj) void i915_gem_object_release_mmap_offset(struct drm_i915_gem_object * obj)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);
} }
#include <net/net_namespace.h>
struct net init_net;
#include <linux/skbuff.h>
void kfree_skb(struct sk_buff * skb)
{
if (!skb)
return;
lx_emul_trace(__func__);
printk("%s:%d: leaking skb: %p\n", __func__, __LINE__, skb);
}
#include <net/net_namespace.h>
int register_pernet_subsys(struct pernet_operations * ops)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/firmware.h>
void release_firmware(const struct firmware * fw)
{
lx_emul_trace(__func__);
}
#include <linux/firmware.h>
int request_firmware(const struct firmware ** firmware_p,const char * name,struct device * device)
{
lx_emul_trace(__func__);
return -1;
}
#include <linux/firmware.h>
int request_firmware_direct(const struct firmware ** firmware_p,const char * name,struct device * device)
{
lx_emul_trace(__func__);
return -1;
}
int ___ratelimit(struct ratelimit_state * rs, const char * func)
{
/*
* from lib/ratelimit.c:
* " 0 means callbacks will be suppressed.
* 1 means go ahead and do it. "
*/
lx_emul_trace(__func__);
return 1;
}
void intel_dsb_prepare(struct intel_crtc_state *crtc_state) void intel_dsb_prepare(struct intel_crtc_state *crtc_state)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);
@ -860,7 +523,6 @@ void intel_dsb_cleanup(struct intel_crtc_state *crtc_state)
} }
void intel_dsb_commit(const struct intel_crtc_state *crtc_state) void intel_dsb_commit(const struct intel_crtc_state *crtc_state)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);

View File

@ -1,12 +1,11 @@
/* /*
* \brief Dummy definitions of Linux Kernel functions * \brief Dummy definitions of Linux Kernel functions
* \author Automatically generated file - do no edit * \author Automatically generated file - do no edit
* \date 2022-03-29 * \date 2022-05-06
*/ */
#include <lx_emul.h> #include <lx_emul.h>
#include "i915_drv.h"
#include <linux/proc_fs.h> #include <linux/proc_fs.h>
@ -87,14 +86,6 @@ void __srcu_read_unlock(struct srcu_struct * ssp,int idx)
} }
#include <linux/interrupt.h>
void __tasklet_schedule(struct tasklet_struct * t)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/fs.h> #include <linux/fs.h>
void __unregister_chrdev(unsigned int major,unsigned int baseminor,unsigned int count,const char * name) void __unregister_chrdev(unsigned int major,unsigned int baseminor,unsigned int count,const char * name)
@ -132,6 +123,13 @@ bool _drm_lease_held(struct drm_file * file_priv,int id)
atomic_long_t _totalram_pages; atomic_long_t _totalram_pages;
extern void ack_bad_irq(unsigned int irq);
void ack_bad_irq(unsigned int irq)
{
lx_emul_trace_and_stop(__func__);
}
#include <acpi/acpi_bus.h> #include <acpi/acpi_bus.h>
int acpi_bus_attach_private_data(acpi_handle handle,void * data) int acpi_bus_attach_private_data(acpi_handle handle,void * data)
@ -407,14 +405,6 @@ void dma_buf_unmap_attachment(struct dma_buf_attachment * attach,struct sg_table
} }
#include <linux/dma-mapping.h>
dma_addr_t dma_map_page_attrs(struct device * dev,struct page * page,size_t offset,size_t size,enum dma_data_direction dir,unsigned long attrs)
{
lx_emul_trace_and_stop(__func__);
}
extern void dma_resv_prune(struct dma_resv * resv); extern void dma_resv_prune(struct dma_resv * resv);
void dma_resv_prune(struct dma_resv * resv) void dma_resv_prune(struct dma_resv * resv)
{ {
@ -422,14 +412,6 @@ void dma_resv_prune(struct dma_resv * resv)
} }
#include <linux/dma-mapping.h>
void dma_unmap_page_attrs(struct device * dev,dma_addr_t addr,size_t size,enum dma_data_direction dir,unsigned long attrs)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/netlink.h> #include <linux/netlink.h>
void do_trace_netlink_extack(const char * msg) void do_trace_netlink_extack(const char * msg)
@ -1224,16 +1206,25 @@ struct pseudo_fs_context * init_pseudo(struct fs_context * fc,unsigned long magi
} }
#include <linux/utsname.h>
struct user_namespace init_user_ns;
#include <linux/init.h> #include <linux/init.h>
bool initcall_debug; bool initcall_debug;
extern void intel_dsb_indexed_reg_write(const struct intel_crtc_state * crtc_state,i915_reg_t reg,u32 val);
void intel_dsb_indexed_reg_write(const struct intel_crtc_state * crtc_state,i915_reg_t reg,u32 val)
{
lx_emul_trace_and_stop(__func__);
}
extern void intel_dsb_reg_write(const struct intel_crtc_state * crtc_state,i915_reg_t reg,u32 val);
void intel_dsb_reg_write(const struct intel_crtc_state * crtc_state,i915_reg_t reg,u32 val)
{
lx_emul_trace_and_stop(__func__);
}
extern int intel_dsi_dcs_init_backlight_funcs(struct intel_connector * intel_connector); extern int intel_dsi_dcs_init_backlight_funcs(struct intel_connector * intel_connector);
int intel_dsi_dcs_init_backlight_funcs(struct intel_connector * intel_connector) int intel_dsi_dcs_init_backlight_funcs(struct intel_connector * intel_connector)
{ {
@ -1459,14 +1450,6 @@ long __sched io_schedule_timeout(long timeout)
} }
#include <asm-generic/logic_io.h>
void iounmap(volatile void __iomem * addr)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/fs.h> #include <linux/fs.h>
void iput(struct inode * inode) void iput(struct inode * inode)
@ -1475,13 +1458,6 @@ void iput(struct inode * inode)
} }
extern bool irq_wait_for_poll(struct irq_desc * desc);
bool irq_wait_for_poll(struct irq_desc * desc)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/irq_work.h> #include <linux/irq_work.h>
void irq_work_tick(void) void irq_work_tick(void)
@ -1573,14 +1549,6 @@ void memunmap(void * addr)
} }
#include <net/netlink.h>
int netlink_rcv_skb(struct sk_buff * skb,int (* cb)(struct sk_buff *,struct nlmsghdr *,struct netlink_ext_ack *))
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/netlink.h> #include <linux/netlink.h>
int netlink_broadcast(struct sock * ssk,struct sk_buff * skb,u32 portid,u32 group,gfp_t allocation) int netlink_broadcast(struct sock * ssk,struct sk_buff * skb,u32 portid,u32 group,gfp_t allocation)
@ -1613,6 +1581,14 @@ bool netlink_ns_capable(const struct sk_buff * skb,struct user_namespace * user_
} }
#include <net/netlink.h>
int netlink_rcv_skb(struct sk_buff * skb,int (* cb)(struct sk_buff *,struct nlmsghdr *,struct netlink_ext_ack *))
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/irq.h> #include <linux/irq.h>
struct irq_chip no_irq_chip; struct irq_chip no_irq_chip;
@ -1699,27 +1675,6 @@ unsigned long pci_cardbus_resource_alignment(struct resource * res)
} }
extern int pci_dev_specific_acs_enabled(struct pci_dev * dev,u16 acs_flags);
int pci_dev_specific_acs_enabled(struct pci_dev * dev,u16 acs_flags)
{
lx_emul_trace_and_stop(__func__);
}
extern int pci_dev_specific_disable_acs_redir(struct pci_dev * dev);
int pci_dev_specific_disable_acs_redir(struct pci_dev * dev)
{
lx_emul_trace_and_stop(__func__);
}
extern int pci_dev_specific_enable_acs(struct pci_dev * dev);
int pci_dev_specific_enable_acs(struct pci_dev * dev)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/pci.h> #include <linux/pci.h>
unsigned int pci_flags; unsigned int pci_flags;
@ -1879,14 +1834,6 @@ void seq_puts(struct seq_file * m,const char * s)
} }
#include <linux/seq_file.h>
void seq_vprintf(struct seq_file * m,const char * f,va_list args)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/mm.h> #include <linux/mm.h>
int set_page_dirty(struct page * page) int set_page_dirty(struct page * page)
@ -1934,14 +1881,6 @@ void show_state_filter(unsigned int state_filter)
} }
#include <linux/fs.h>
void simple_release_fs(struct vfsmount ** mount,int * count)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/skbuff.h> #include <linux/skbuff.h>
struct sk_buff * skb_copy_expand(const struct sk_buff * skb,int newheadroom,int newtailroom,gfp_t gfp_mask) struct sk_buff * skb_copy_expand(const struct sk_buff * skb,int newheadroom,int newtailroom,gfp_t gfp_mask)
@ -2079,14 +2018,6 @@ void unregister_irq_proc(unsigned int irq,struct irq_desc * desc)
} }
#include <linux/vmalloc.h>
void vfree(const void * addr)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/vmalloc.h> #include <linux/vmalloc.h>
void * vmap(struct page ** pages,unsigned int count,unsigned long flags,pgprot_t prot) void * vmap(struct page ** pages,unsigned int count,unsigned long flags,pgprot_t prot)
@ -2110,16 +2041,3 @@ void wake_q_add_safe(struct wake_q_head * head,struct task_struct * task)
lx_emul_trace_and_stop(__func__); lx_emul_trace_and_stop(__func__);
} }
void intel_dsb_reg_write(const struct intel_crtc_state *crtc_state,
i915_reg_t reg, u32 val)
{
lx_emul_trace_and_stop(__func__);
}
void intel_dsb_indexed_reg_write(const struct intel_crtc_state *crtc_state,
i915_reg_t reg, u32 val)
{
lx_emul_trace_and_stop(__func__);
}

View File

@ -24,21 +24,8 @@
#include <drm/drm_managed.h> #include <drm/drm_managed.h>
/* support for arch/x86/lib/delay.c, normally defined in init/main.c */
unsigned long loops_per_jiffy = (1<<12);
struct dma_fence_ops const i915_fence_ops; struct dma_fence_ops const i915_fence_ops;
/* early_identify_cpu() in linux sets this up normally, used by drm_cache */
struct cpuinfo_x86 boot_cpu_data =
{
.x86_clflush_size = (sizeof(void*) == 8) ? 64 : 32,
.x86_cache_alignment = (sizeof(void*) == 8) ? 64 : 32,
.x86_phys_bits = (sizeof(void*) == 8) ? 36 : 32,
.x86_virt_bits = (sizeof(void*) == 8) ? 48 : 32
};
/* Bits allowed in normal kernel mappings: */ /* Bits allowed in normal kernel mappings: */
pteval_t __default_kernel_pte_mask __read_mostly = ~0; pteval_t __default_kernel_pte_mask __read_mostly = ~0;
@ -53,52 +40,6 @@ void intel_wopcm_init_early(struct intel_wopcm * wopcm)
} }
void * kmalloc_order(size_t size,gfp_t flags, unsigned int order)
{
lx_emul_trace(__func__);
return kmalloc(size, flags);
}
int simple_pin_fs(struct file_system_type *type, struct vfsmount ** mount, int * count)
{
lx_emul_trace(__func__);
if (!mount)
return -EFAULT;
if (!*mount)
*mount = kzalloc(sizeof(struct vfsmount), GFP_KERNEL);
if (!*mount)
return -ENOMEM;
if (count)
++*count;
return 0;
}
struct inode * alloc_anon_inode(struct super_block * s)
{
lx_emul_trace(__func__);
return kzalloc(sizeof(struct inode), GFP_KERNEL);
}
struct proc_dir_entry { char dummy [512]; };
struct proc_dir_entry * proc_create_seq_private(const char * name,umode_t mode,struct proc_dir_entry * parent,const struct seq_operations * ops,unsigned int state_size,void * data)
{
static struct proc_dir_entry ret;
lx_emul_trace(__func__);
return &ret;
}
void si_meminfo(struct sysinfo * val) void si_meminfo(struct sysinfo * val)
{ {
/* 4M, ttm actually use only half - more or configurable XXX ? */ /* 4M, ttm actually use only half - more or configurable XXX ? */
@ -119,19 +60,6 @@ void si_meminfo(struct sysinfo * val)
void __iomem * ioremap(resource_size_t phys_addr, unsigned long size)
{
return lx_emul_io_mem_map(phys_addr, size);
}
int dma_supported(struct device * dev, u64 mask)
{
lx_emul_trace(__func__);
return 1;
}
void yield() void yield()
{ {
lx_emul_task_schedule(false /* no block */); lx_emul_task_schedule(false /* no block */);
@ -151,19 +79,6 @@ int fb_get_options(const char * name,char ** option)
} }
void ack_bad_irq(unsigned int irq)
{
lx_emul_trace(__func__);
}
bool pat_enabled(void)
{
lx_emul_trace(__func__);
return true;
}
pgprot_t pgprot_writecombine(pgprot_t prot) pgprot_t pgprot_writecombine(pgprot_t prot)
{ {
pgprot_t p = { .pgprot = 0 }; pgprot_t p = { .pgprot = 0 };
@ -286,27 +201,6 @@ bool is_swiotlb_active(void)
#endif #endif
/* linux/mm/page_alloc.c */
unsigned long __get_free_pages(gfp_t gfp_mask, unsigned int order)
{
struct page *page = alloc_pages(gfp_mask & ~__GFP_HIGHMEM, order);
if (!page)
return 0;
return (unsigned long) page_address(page);
}
/* linux/mm/page_alloc.c */
void free_pages(unsigned long addr, unsigned int order)
{
if (addr != 0) {
__free_pages(virt_to_page((void *)addr), order);
}
}
void intel_gt_init_early(struct intel_gt * gt, struct drm_i915_private * i915) void intel_gt_init_early(struct intel_gt * gt, struct drm_i915_private * i915)
{ {
gt->i915 = i915; gt->i915 = i915;
@ -343,13 +237,6 @@ void intel_rps_mark_interactive(struct intel_rps * rps, bool interactive)
} }
bool is_vmalloc_addr(const void * addr)
{
lx_emul_trace(__func__);
return false;
}
void * memremap(resource_size_t offset, size_t size, unsigned long flags) void * memremap(resource_size_t offset, size_t size, unsigned long flags)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);
@ -371,18 +258,3 @@ void intel_vgpu_detect(struct drm_i915_private * dev_priv)
printk("disabling PPGTT to avoid GPU code paths\n"); printk("disabling PPGTT to avoid GPU code paths\n");
} }
void call_rcu(struct rcu_head * head, rcu_callback_t func)
{
enum { KVFREE_RCU_OFFSET = 4096 };
lx_emul_trace(__func__);
if (func < (rcu_callback_t)KVFREE_RCU_OFFSET) {
kvfree((void*)head - (unsigned long)func);
return;
}
func(head);
}

View File

@ -0,0 +1,28 @@
arch/x86/include/asm/atomic64_64.h
arch/x86/include/asm/checksum_32.h
arch/x86/include/asm/checksum_64.h
arch/x86/include/asm/cmpxchg_32.h
arch/x86/include/asm/cmpxchg_64.h
arch/x86/include/asm/io.h
arch/x86/include/asm/io_apic.h
arch/x86/include/asm/kaslr.h
arch/x86/include/asm/numa_32.h
arch/x86/include/asm/page_32.h
arch/x86/include/asm/page_32_types.h
arch/x86/include/asm/page_64_types.h
arch/x86/include/asm/pgtable-2level_types.h
arch/x86/include/asm/pgtable_32_areas.h
arch/x86/include/asm/pgtable_32_types.h
arch/x86/include/asm/pgtable_64_types.h
arch/x86/include/asm/sparsemem.h
arch/x86/include/asm/string_64.h
arch/x86/include/asm/user_32.h
arch/x86/include/asm/user_64.h
arch/x86/include/uapi/asm/posix_types_32.h
arch/x86/include/uapi/asm/posix_types_64.h
arch/x86/include/uapi/asm/vsyscall.h
include/asm-generic/asm-prototypes.h
include/asm-generic/bitops/fls64.h
include/asm-generic/div64.h
include/asm-generic/pgtable-nopmd.h
include/asm-generic/pgtable-nopud.h

View File

@ -0,0 +1,3 @@
arch/x86/include/asm/io.h
arch/x86/include/asm/io_apic.h
arch/x86/include/asm/iomap.h

View File

@ -10,7 +10,6 @@ INC_DIR += $(REL_PRG_DIR)/shadow
SRC_CC += main.cc SRC_CC += main.cc
SRC_CC += misc.cc SRC_CC += misc.cc
SRC_CC += time.cc
SRC_CC += emul.cc SRC_CC += emul.cc
SRC_C += dummies.c SRC_C += dummies.c
SRC_C += lx_emul.c SRC_C += lx_emul.c
@ -19,13 +18,16 @@ SRC_C += fb.c
SRC_C += lx_user.c SRC_C += lx_user.c
SRC_C += gem.c SRC_C += gem.c
SRC_C += timeout.c SRC_C += timeout.c
SRC_C += common_dummies.c SRC_C += lx_emul/common_dummies.c
SRC_C += lx_emul/spec/x86/pci.c SRC_C += lx_emul/spec/x86/pci.c
SRC_C += lx_emul/shadow/mm/page_alloc.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 %.cc $(REL_PRG_DIR)
vpath common_dummies.c $(REP_DIR)/src/lib/pc/lx_emul
vpath %.c $(REP_DIR)/src/lib/pc
vpath %.cc $(REP_DIR)/src/lib/pc
LX_SRC_DIR := $(call select_from_ports,linux)/src/linux LX_SRC_DIR := $(call select_from_ports,linux)/src/linux
ifeq ($(wildcard $(LX_SRC_DIR)),) ifeq ($(wildcard $(LX_SRC_DIR)),)
@ -37,6 +39,13 @@ endif
INC_DIR += $(LX_SRC_DIR)/drivers/gpu/drm/i915 INC_DIR += $(LX_SRC_DIR)/drivers/gpu/drm/i915
#
# The generated dummies file pulls in functions without header
# includes so we force the inclusion of i915_drv explicitly for
# this compilation unit.
#
CC_OPT_generated_dummies += -include $(LX_SRC_DIR)/drivers/gpu/drm/i915/i915_drv.h
CC_C_OPT += -Wno-unused-label CC_C_OPT += -Wno-unused-label
# #

View File

@ -1,25 +0,0 @@
/*
* \brief Lx_emul udelay function for very short delays
* \author Stefan Kalkowski
* \date 2021-07-10
*/
/*
* Copyright (C) 2021 Genode Labs GmbH
*
* This file is distributed under the terms of the GNU General Public License
* version 2.
*/
#include <base/log.h>
#include <lx_kit/env.h>
extern "C" void lx_emul_time_udelay(unsigned long usec);
extern "C" void lx_emul_time_udelay(unsigned long usec)
{
if (usec > 100)
Genode::error("Cannot delay that long ", usec, " microseconds");
auto start = Lx_kit::env().timer.curr_time().trunc_to_plain_us().value;
while (Lx_kit::env().timer.curr_time().trunc_to_plain_us().value < (start + usec)) { ; }
}

View File

@ -1,149 +1,4 @@
arch/x86/include/asm/acenv.h
arch/x86/include/asm/acpi.h
arch/x86/include/asm/alternative.h
arch/x86/include/asm/apicdef.h
arch/x86/include/asm/arch_hweight.h
arch/x86/include/asm/asm.h
arch/x86/include/asm/atomic.h
arch/x86/include/asm/barrier.h
arch/x86/include/asm/bitops.h
arch/x86/include/asm/bug.h
arch/x86/include/asm/cache.h
arch/x86/include/asm/cacheflush.h
arch/x86/include/asm/checksum.h
arch/x86/include/asm/clocksource.h
arch/x86/include/asm/cmpxchg.h
arch/x86/include/asm/compat.h
arch/x86/include/asm/cpu_entry_area.h
arch/x86/include/asm/cpufeatures.h
arch/x86/include/asm/cpumask.h
arch/x86/include/asm/delay.h
arch/x86/include/asm/desc.h
arch/x86/include/asm/desc_defs.h
arch/x86/include/asm/device.h
arch/x86/include/asm/disabled-features.h
arch/x86/include/asm/div64.h
arch/x86/include/asm/dma.h
arch/x86/include/asm/elf.h
arch/x86/include/asm/emergency-restart.h
arch/x86/include/asm/exec.h
arch/x86/include/asm/extable.h
arch/x86/include/asm/fixmap.h
arch/x86/include/asm/fpu/types.h
arch/x86/include/asm/fsgsbase.h
arch/x86/include/asm/ftrace.h
arch/x86/include/asm/hardirq.h
arch/x86/include/asm/hw_breakpoint.h
arch/x86/include/asm/hw_irq.h
arch/x86/include/asm/intel_ds.h
arch/x86/include/asm/invpcid.h
arch/x86/include/asm/io.h
arch/x86/include/asm/iosf_mbi.h
arch/x86/include/asm/irq.h
arch/x86/include/asm/irq_vectors.h
arch/x86/include/asm/irq_work.h
arch/x86/include/asm/irqdomain.h
arch/x86/include/asm/ist.h
arch/x86/include/asm/jailhouse_para.h
arch/x86/include/asm/kdebug.h
arch/x86/include/asm/kgdb.h
arch/x86/include/asm/kprobes.h
arch/x86/include/asm/kvm_para.h
arch/x86/include/asm/linkage.h
arch/x86/include/asm/local.h
arch/x86/include/asm/math_emu.h
arch/x86/include/asm/mem_encrypt.h
arch/x86/include/asm/memtype.h
arch/x86/include/asm/mmu.h
arch/x86/include/asm/mmu_context.h
arch/x86/include/asm/module.h
arch/x86/include/asm/mpspec.h
arch/x86/include/asm/mpspec_def.h
arch/x86/include/asm/msi.h
arch/x86/include/asm/msr-index.h
arch/x86/include/asm/msr.h
arch/x86/include/asm/nmi.h
arch/x86/include/asm/nops.h
arch/x86/include/asm/numa.h
arch/x86/include/asm/numa_32.h
arch/x86/include/asm/orc_types.h
arch/x86/include/asm/page_types.h
arch/x86/include/asm/paravirt.h
arch/x86/include/asm/pci.h
arch/x86/include/asm/pci_x86.h
arch/x86/include/asm/percpu.h
arch/x86/include/asm/perf_event.h
arch/x86/include/asm/pgtable_areas.h
arch/x86/include/asm/pgtable_types.h
arch/x86/include/asm/posix_types.h
arch/x86/include/asm/preempt.h
arch/x86/include/asm/processor-flags.h
arch/x86/include/asm/processor.h
arch/x86/include/asm/proto.h
arch/x86/include/asm/pti.h
arch/x86/include/asm/ptrace.h
arch/x86/include/asm/required-features.h
arch/x86/include/asm/rmwcc.h
arch/x86/include/asm/segment.h
arch/x86/include/asm/set_memory.h
arch/x86/include/asm/shmparam.h
arch/x86/include/asm/signal.h
arch/x86/include/asm/smap.h
arch/x86/include/asm/smp.h
arch/x86/include/asm/special_insns.h
arch/x86/include/asm/stacktrace.h
arch/x86/include/asm/static_call.h
arch/x86/include/asm/string.h
arch/x86/include/asm/syscall_wrapper.h
arch/x86/include/asm/text-patching.h
arch/x86/include/asm/thread_info.h
arch/x86/include/asm/timex.h
arch/x86/include/asm/tlb.h
arch/x86/include/asm/tlbbatch.h
arch/x86/include/asm/tlbflush.h
arch/x86/include/asm/topology.h
arch/x86/include/asm/trace_clock.h
arch/x86/include/asm/tsc.h
arch/x86/include/asm/uaccess.h
arch/x86/include/asm/unistd.h
arch/x86/include/asm/unwind_hints.h
arch/x86/include/asm/user.h
arch/x86/include/asm/user32.h
arch/x86/include/asm/vdso.h
arch/x86/include/asm/vdso/clocksource.h
arch/x86/include/asm/vdso/processor.h arch/x86/include/asm/vdso/processor.h
arch/x86/include/asm/vga.h
arch/x86/include/asm/vmalloc.h
arch/x86/include/asm/vmxfeatures.h
arch/x86/include/asm/word-at-a-time.h
arch/x86/include/asm/x86_init.h
arch/x86/include/uapi/asm/auxvec.h
arch/x86/include/uapi/asm/bitsperlong.h
arch/x86/include/uapi/asm/bootparam.h
arch/x86/include/uapi/asm/byteorder.h
arch/x86/include/uapi/asm/hw_breakpoint.h
arch/x86/include/uapi/asm/ist.h
arch/x86/include/uapi/asm/kvm_para.h
arch/x86/include/uapi/asm/ldt.h
arch/x86/include/uapi/asm/mman.h
arch/x86/include/uapi/asm/msr.h
arch/x86/include/uapi/asm/perf_regs.h
arch/x86/include/uapi/asm/processor-flags.h
arch/x86/include/uapi/asm/ptrace-abi.h
arch/x86/include/uapi/asm/ptrace.h
arch/x86/include/uapi/asm/sembuf.h
arch/x86/include/uapi/asm/shmbuf.h
arch/x86/include/uapi/asm/sigcontext.h
arch/x86/include/uapi/asm/siginfo.h
arch/x86/include/uapi/asm/signal.h
arch/x86/include/uapi/asm/stat.h
arch/x86/include/uapi/asm/swab.h
arch/x86/include/uapi/asm/unistd.h
drivers/base/base.h
drivers/base/power/power.h
drivers/base/trace.h
drivers/pci/pci.h
drivers/pci/pcie/portdrv.h
drivers/usb/common/common.h drivers/usb/common/common.h
drivers/usb/core/hub.h drivers/usb/core/hub.h
drivers/usb/core/otg_productlist.h drivers/usb/core/otg_productlist.h
@ -174,577 +29,18 @@ drivers/usb/host/xhci-ext-caps.h
drivers/usb/host/xhci-pci.h drivers/usb/host/xhci-pci.h
drivers/usb/host/xhci-trace.h drivers/usb/host/xhci-trace.h
drivers/usb/host/xhci.h drivers/usb/host/xhci.h
include/acpi/acbuffer.h
include/acpi/acconfig.h
include/acpi/acexcep.h
include/acpi/acnames.h
include/acpi/acoutput.h
include/acpi/acpi.h
include/acpi/acpi_numa.h
include/acpi/acpiosxf.h
include/acpi/acpixf.h
include/acpi/acrestyp.h
include/acpi/actbl.h
include/acpi/actbl1.h
include/acpi/actbl2.h
include/acpi/actbl3.h
include/acpi/actypes.h
include/acpi/platform/acenv.h
include/acpi/platform/acenvex.h
include/acpi/platform/acgcc.h
include/acpi/platform/acgccex.h
include/acpi/platform/aclinux.h
include/acpi/platform/aclinuxex.h
include/asm-generic/asm-prototypes.h
include/asm-generic/atomic-instrumented.h
include/asm-generic/atomic-long.h
include/asm-generic/barrier.h
include/asm-generic/bitops/const_hweight.h
include/asm-generic/bitops/ext2-atomic-setbit.h
include/asm-generic/bitops/find.h
include/asm-generic/bitops/instrumented-atomic.h
include/asm-generic/bitops/instrumented-lock.h
include/asm-generic/bitops/instrumented-non-atomic.h
include/asm-generic/bitops/le.h
include/asm-generic/bitops/sched.h
include/asm-generic/bitsperlong.h
include/asm-generic/bug.h
include/asm-generic/cacheflush.h
include/asm-generic/compat.h
include/asm-generic/delay.h
include/asm-generic/early_ioremap.h
include/asm-generic/error-injection.h
include/asm-generic/export.h include/asm-generic/export.h
include/asm-generic/fixmap.h
include/asm-generic/getorder.h
include/asm-generic/int-ll64.h
include/asm-generic/io.h
include/asm-generic/ioctl.h
include/asm-generic/iomap.h
include/asm-generic/irq_regs.h
include/asm-generic/kmap_size.h
include/asm-generic/kprobes.h
include/asm-generic/local64.h
include/asm-generic/logic_io.h
include/asm-generic/mmiowb.h
include/asm-generic/mmu_context.h
include/asm-generic/module.h
include/asm-generic/param.h
include/asm-generic/pci.h
include/asm-generic/pci_iomap.h
include/asm-generic/percpu.h
include/asm-generic/pgtable-nop4d.h
include/asm-generic/resource.h
include/asm-generic/rwonce.h
include/asm-generic/sections.h
include/asm-generic/set_memory.h
include/asm-generic/termios.h
include/asm-generic/tlb.h
include/asm-generic/topology.h
include/asm-generic/unaligned.h
include/crypto/sha1.h
include/linux/acpi.h
include/linux/acpi_iort.h
include/linux/aer.h
include/linux/alarmtimer.h
include/linux/align.h
include/linux/apm_bios.h
include/linux/arch_topology.h
include/linux/assoc_array.h
include/linux/async.h
include/linux/atomic-arch-fallback.h
include/linux/atomic.h
include/linux/audit.h
include/linux/auxvec.h
include/linux/backing-dev-defs.h
include/linux/bcd.h include/linux/bcd.h
include/linux/binfmts.h
include/linux/bio.h
include/linux/bit_spinlock.h
include/linux/bitfield.h
include/linux/bitmap.h
include/linux/bitops.h
include/linux/bitrev.h
include/linux/bits.h
include/linux/blk-cgroup.h
include/linux/blk_types.h
include/linux/blkdev.h
include/linux/bottom_half.h
include/linux/bpf-cgroup.h
include/linux/bpf-netns.h
include/linux/bpf.h
include/linux/bpfptr.h
include/linux/bsg.h
include/linux/bug.h
include/linux/build_bug.h
include/linux/buildid.h
include/linux/bvec.h
include/linux/byteorder/generic.h
include/linux/byteorder/little_endian.h
include/linux/cache.h
include/linux/capability.h
include/linux/cc_platform.h
include/linux/cdev.h
include/linux/cfi.h
include/linux/cgroup-defs.h
include/linux/cgroup.h
include/linux/clk-provider.h
include/linux/clk.h
include/linux/clk/clk-conf.h
include/linux/clockchips.h
include/linux/clocksource.h
include/linux/clocksource_ids.h
include/linux/compat.h
include/linux/compiler-gcc.h
include/linux/compiler.h
include/linux/compiler_attributes.h
include/linux/compiler_types.h
include/linux/completion.h
include/linux/component.h
include/linux/console.h
include/linux/console_struct.h
include/linux/consolemap.h
include/linux/const.h
include/linux/context_tracking.h
include/linux/context_tracking_state.h
include/linux/cpu.h
include/linux/cpufreq.h
include/linux/cpuhotplug.h
include/linux/cpuidle.h
include/linux/cpumask.h
include/linux/cpuset.h
include/linux/crash_core.h
include/linux/crc32.h
include/linux/crc32poly.h
include/linux/cred.h
include/linux/ctype.h
include/linux/dax.h
include/linux/dcache.h
include/linux/debug_locks.h
include/linux/debugfs.h
include/linux/debugobjects.h
include/linux/delay.h
include/linux/delayacct.h
include/linux/delayed_call.h
include/linux/dev_printk.h
include/linux/device.h
include/linux/device/bus.h
include/linux/device/class.h
include/linux/device/driver.h
include/linux/dma-direction.h
include/linux/dma-map-ops.h
include/linux/dma-mapping.h
include/linux/dmapool.h
include/linux/dmi.h
include/linux/dqblk_qtree.h
include/linux/dqblk_v1.h
include/linux/dqblk_v2.h
include/linux/dynamic_debug.h
include/linux/dynamic_queue_limits.h
include/linux/edd.h
include/linux/elevator.h
include/linux/elf-randomize.h
include/linux/elf.h
include/linux/elfcore.h
include/linux/energy_model.h
include/linux/err.h
include/linux/errname.h
include/linux/errno.h
include/linux/error-injection.h
include/linux/errseq.h
include/linux/etherdevice.h
include/linux/ethtool.h
include/linux/eventfd.h
include/linux/export.h
include/linux/extcon.h include/linux/extcon.h
include/linux/fault-inject-usercopy.h
include/linux/fault-inject.h
include/linux/fcntl.h
include/linux/file.h
include/linux/filter.h
include/linux/flex_proportions.h
include/linux/freelist.h
include/linux/freezer.h
include/linux/fs.h
include/linux/fs_context.h
include/linux/fs_types.h
include/linux/ftrace.h
include/linux/ftrace_irq.h
include/linux/fwnode.h
include/linux/genalloc.h include/linux/genalloc.h
include/linux/genhd.h
include/linux/gfp.h
include/linux/gpio/consumer.h
include/linux/hardirq.h
include/linux/hash.h
include/linux/hashtable.h
include/linux/highmem-internal.h
include/linux/highmem.h
include/linux/highuid.h
include/linux/hrtimer.h
include/linux/hrtimer_defs.h
include/linux/huge_mm.h
include/linux/hugetlb.h
include/linux/hugetlb_inline.h
include/linux/hypervisor.h
include/linux/icmpv6.h
include/linux/idr.h
include/linux/if_arp.h
include/linux/if_ether.h
include/linux/if_link.h
include/linux/if_vlan.h
include/linux/in.h
include/linux/in6.h
include/linux/indirect_call_wrapper.h
include/linux/init.h
include/linux/init_task.h
include/linux/instrumentation.h
include/linux/instrumented.h
include/linux/interrupt.h
include/linux/interval_tree.h
include/linux/io-64-nonatomic-lo-hi.h include/linux/io-64-nonatomic-lo-hi.h
include/linux/io.h
include/linux/iocontext.h
include/linux/iopoll.h
include/linux/ioport.h
include/linux/ioprio.h
include/linux/ipc.h
include/linux/ipv6.h
include/linux/irq.h
include/linux/irq_work.h
include/linux/irqchip.h
include/linux/irqdesc.h
include/linux/irqdomain.h
include/linux/irqflags.h
include/linux/irqhandler.h
include/linux/irqnr.h
include/linux/irqreturn.h
include/linux/jhash.h
include/linux/jiffies.h
include/linux/jump_label.h
include/linux/jump_label_ratelimit.h
include/linux/kallsyms.h
include/linux/kasan-checks.h
include/linux/kasan.h
include/linux/kconfig.h
include/linux/kcov.h include/linux/kcov.h
include/linux/kcsan-checks.h
include/linux/kcsan.h
include/linux/kdebug.h
include/linux/kdev_t.h
include/linux/kern_levels.h
include/linux/kernel.h
include/linux/kernel_read_file.h
include/linux/kernel_stat.h
include/linux/kernfs.h
include/linux/kexec.h
include/linux/key.h
include/linux/kfifo.h include/linux/kfifo.h
include/linux/kgdb.h
include/linux/klist.h
include/linux/kmemleak.h
include/linux/kmod.h
include/linux/kmsg_dump.h
include/linux/kobject.h
include/linux/kobject_ns.h
include/linux/kprobes.h
include/linux/kref.h
include/linux/kstrtox.h
include/linux/kthread.h
include/linux/ktime.h
include/linux/kvm_para.h
include/linux/latencytop.h
include/linux/limits.h
include/linux/linkage.h
include/linux/linkmode.h
include/linux/list.h
include/linux/list_bl.h
include/linux/list_lru.h
include/linux/list_nulls.h
include/linux/list_sort.h
include/linux/livepatch.h
include/linux/llist.h
include/linux/local_lock.h
include/linux/local_lock_internal.h
include/linux/lockdep.h
include/linux/lockdep_types.h
include/linux/lockref.h
include/linux/log2.h
include/linux/logic_pio.h
include/linux/math.h
include/linux/math64.h
include/linux/mdio.h
include/linux/mem_encrypt.h
include/linux/memblock.h
include/linux/memcontrol.h
include/linux/memory_hotplug.h
include/linux/mempolicy.h
include/linux/mempool.h
include/linux/memremap.h
include/linux/migrate.h
include/linux/migrate_mode.h
include/linux/mii.h
include/linux/mii_timestamper.h
include/linux/minmax.h
include/linux/mm.h
include/linux/mm_types.h
include/linux/mm_types_task.h
include/linux/mman.h
include/linux/mmap_lock.h
include/linux/mmdebug.h
include/linux/mmu_context.h
include/linux/mmu_notifier.h
include/linux/mmzone.h
include/linux/mod_devicetable.h
include/linux/module.h
include/linux/moduleparam.h
include/linux/mount.h
include/linux/msi.h
include/linux/mutex.h
include/linux/net.h
include/linux/netdev_features.h
include/linux/netdevice.h
include/linux/netfilter_defs.h
include/linux/netlink.h
include/linux/nfs_fs_i.h
include/linux/nls.h
include/linux/nmi.h
include/linux/node.h
include/linux/nodemask.h
include/linux/notifier.h
include/linux/ns_common.h
include/linux/nsproxy.h
include/linux/numa.h
include/linux/nvmem-provider.h
include/linux/objtool.h
include/linux/of.h
include/linux/of_address.h
include/linux/of_clk.h
include/linux/of_device.h
include/linux/of_fdt.h
include/linux/of_graph.h
include/linux/of_irq.h
include/linux/of_pci.h
include/linux/of_platform.h
include/linux/once.h
include/linux/once_lite.h
include/linux/osq_lock.h
include/linux/overflow.h
include/linux/page-flags-layout.h
include/linux/page-flags.h
include/linux/page_counter.h
include/linux/page_ext.h
include/linux/page_ref.h
include/linux/pageblock-flags.h
include/linux/pagemap.h
include/linux/panic.h
include/linux/panic_notifier.h
include/linux/path.h
include/linux/pci-dma-compat.h
include/linux/pci.h
include/linux/pci_hotplug.h
include/linux/pci_ids.h
include/linux/percpu-defs.h
include/linux/percpu-refcount.h
include/linux/percpu-rwsem.h
include/linux/percpu.h
include/linux/percpu_counter.h
include/linux/perf_event.h
include/linux/perf_regs.h
include/linux/personality.h
include/linux/pfn.h
include/linux/phy.h
include/linux/phy/phy-dp.h include/linux/phy/phy-dp.h
include/linux/phy/phy-mipi-dphy.h include/linux/phy/phy-mipi-dphy.h
include/linux/phy/phy.h include/linux/phy/phy.h
include/linux/pid.h
include/linux/pid_namespace.h
include/linux/pinctrl/devinfo.h
include/linux/pipe_fs_i.h
include/linux/pkeys.h
include/linux/platform_device.h
include/linux/plist.h
include/linux/pm.h
include/linux/pm_domain.h
include/linux/pm_qos.h
include/linux/pm_runtime.h
include/linux/pm_wakeup.h
include/linux/poison.h
include/linux/poll.h
include/linux/posix-timers.h
include/linux/prandom.h
include/linux/preempt.h
include/linux/prefetch.h
include/linux/printk.h
include/linux/proc_fs.h
include/linux/processor.h
include/linux/profile.h
include/linux/projid.h
include/linux/property.h
include/linux/pseudo_fs.h
include/linux/psi.h
include/linux/psi_types.h
include/linux/ptr_ring.h
include/linux/ptrace.h
include/linux/pvclock_gtod.h
include/linux/quota.h
include/linux/radix-tree.h
include/linux/random.h
include/linux/range.h
include/linux/ratelimit.h
include/linux/ratelimit_types.h
include/linux/rbtree.h
include/linux/rbtree_augmented.h
include/linux/rbtree_latch.h
include/linux/rcu_segcblist.h
include/linux/rcu_sync.h
include/linux/rculist.h
include/linux/rculist_bl.h
include/linux/rculist_nulls.h
include/linux/rcupdate.h
include/linux/rcupdate_wait.h
include/linux/rcutiny.h
include/linux/rcuwait.h
include/linux/reboot.h
include/linux/refcount.h
include/linux/regulator/consumer.h include/linux/regulator/consumer.h
include/linux/reset.h include/linux/reset.h
include/linux/resource.h
include/linux/resource_ext.h
include/linux/restart_block.h
include/linux/rhashtable-types.h
include/linux/ring_buffer.h
include/linux/rtc.h
include/linux/rtnetlink.h
include/linux/rwlock.h
include/linux/rwlock_types.h
include/linux/rwsem.h
include/linux/sbitmap.h
include/linux/scatterlist.h
include/linux/sched.h
include/linux/sched/autogroup.h
include/linux/sched/clock.h
include/linux/sched/coredump.h
include/linux/sched/cpufreq.h
include/linux/sched/cputime.h
include/linux/sched/deadline.h
include/linux/sched/debug.h
include/linux/sched/hotplug.h
include/linux/sched/idle.h
include/linux/sched/init.h
include/linux/sched/isolation.h
include/linux/sched/jobctl.h
include/linux/sched/loadavg.h
include/linux/sched/mm.h
include/linux/sched/nohz.h
include/linux/sched/numa_balancing.h
include/linux/sched/prio.h
include/linux/sched/rt.h
include/linux/sched/signal.h
include/linux/sched/smt.h
include/linux/sched/stat.h
include/linux/sched/sysctl.h
include/linux/sched/task.h
include/linux/sched/task_stack.h
include/linux/sched/topology.h
include/linux/sched/types.h
include/linux/sched/user.h
include/linux/sched/wake_q.h
include/linux/sched/xacct.h
include/linux/sched_clock.h
include/linux/screen_info.h
include/linux/seccomp.h
include/linux/securebits.h
include/linux/security.h
include/linux/sem.h
include/linux/semaphore.h
include/linux/seq_buf.h
include/linux/seq_file.h
include/linux/seq_file_net.h
include/linux/seqlock.h
include/linux/set_memory.h
include/linux/shm.h
include/linux/shrinker.h
include/linux/signal.h
include/linux/signal_types.h
include/linux/siphash.h
include/linux/sizes.h
include/linux/skbuff.h
include/linux/slab.h
include/linux/smp.h
include/linux/smp_types.h
include/linux/smpboot.h
include/linux/socket.h
include/linux/sockptr.h
include/linux/sort.h
include/linux/spinlock.h
include/linux/spinlock_api_up.h
include/linux/spinlock_types.h
include/linux/spinlock_types_up.h
include/linux/spinlock_up.h
include/linux/splice.h
include/linux/srcu.h
include/linux/srcutiny.h
include/linux/stackdepot.h
include/linux/stacktrace.h
include/linux/stat.h
include/linux/static_call.h
include/linux/static_call_types.h
include/linux/static_key.h
include/linux/stddef.h
include/linux/stop_machine.h
include/linux/string.h
include/linux/string_helpers.h
include/linux/stringhash.h
include/linux/stringify.h
include/linux/suspend.h
include/linux/swab.h
include/linux/swait.h
include/linux/swap.h
include/linux/sync_core.h
include/linux/syscall_user_dispatch.h
include/linux/syscalls.h
include/linux/syscore_ops.h
include/linux/sysctl.h
include/linux/sysfs.h
include/linux/sysrq.h
include/linux/task_io_accounting.h
include/linux/task_work.h
include/linux/tcp.h
include/linux/textsearch.h
include/linux/thread_info.h
include/linux/threads.h
include/linux/tick.h
include/linux/time.h
include/linux/time32.h
include/linux/time64.h
include/linux/timecounter.h
include/linux/timekeeper_internal.h
include/linux/timekeeping.h
include/linux/timer.h
include/linux/timerqueue.h
include/linux/timex.h
include/linux/topology.h
include/linux/trace_clock.h
include/linux/trace_events.h
include/linux/trace_recursion.h
include/linux/trace_seq.h
include/linux/tracepoint-defs.h
include/linux/tracepoint.h
include/linux/tsacct_kern.h
include/linux/tty.h
include/linux/tty_driver.h
include/linux/tty_ldisc.h
include/linux/typecheck.h
include/linux/types.h
include/linux/u64_stats_sync.h
include/linux/uaccess.h
include/linux/udp.h
include/linux/uidgid.h
include/linux/uio.h
include/linux/umh.h
include/linux/unaligned/packed_struct.h
include/linux/uprobes.h
include/linux/usb.h include/linux/usb.h
include/linux/usb/cdc.h include/linux/usb/cdc.h
include/linux/usb/ch9.h include/linux/usb/ch9.h
@ -756,265 +52,10 @@ include/linux/usb/otg.h
include/linux/usb/phy.h include/linux/usb/phy.h
include/linux/usb/quirks.h include/linux/usb/quirks.h
include/linux/usbdevice_fs.h include/linux/usbdevice_fs.h
include/linux/user.h
include/linux/user_namespace.h
include/linux/userfaultfd_k.h
include/linux/utsname.h
include/linux/uuid.h
include/linux/vgaarb.h
include/linux/vm_event_item.h
include/linux/vmalloc.h
include/linux/vmpressure.h
include/linux/vmstat.h
include/linux/vt.h
include/linux/vt_kern.h
include/linux/vtime.h
include/linux/wait.h
include/linux/wait_bit.h
include/linux/win_minmax.h
include/linux/workqueue.h
include/linux/writeback.h
include/linux/ww_mutex.h
include/linux/xarray.h
include/net/addrconf.h
include/net/checksum.h
include/net/dst.h
include/net/dst_ops.h
include/net/fib_notifier.h
include/net/fib_rules.h
include/net/flow.h
include/net/flow_dissector.h
include/net/flow_offload.h
include/net/gen_stats.h
include/net/if_inet6.h
include/net/inet_connection_sock.h
include/net/inet_frag.h
include/net/inet_sock.h
include/net/inet_timewait_sock.h
include/net/ipv6.h
include/net/ipv6_stubs.h
include/net/l3mdev.h
include/net/ndisc.h
include/net/neighbour.h
include/net/net_namespace.h
include/net/netlink.h
include/net/netns/bpf.h
include/net/netns/can.h
include/net/netns/core.h
include/net/netns/hash.h
include/net/netns/ieee802154_6lowpan.h
include/net/netns/ipv4.h
include/net/netns/ipv6.h
include/net/netns/mib.h
include/net/netns/mpls.h
include/net/netns/netfilter.h
include/net/netns/nexthop.h
include/net/netns/nftables.h
include/net/netns/packet.h
include/net/netns/sctp.h
include/net/netns/smc.h
include/net/netns/unix.h
include/net/netns/x_tables.h
include/net/netns/xdp.h
include/net/netns/xfrm.h
include/net/netprio_cgroup.h
include/net/page_pool.h
include/net/request_sock.h
include/net/rtnetlink.h
include/net/sch_generic.h
include/net/scm.h
include/net/snmp.h
include/net/sock.h
include/net/tcp_states.h
include/net/timewait_sock.h
include/net/xdp.h
include/trace/define_trace.h
include/trace/events/irq.h
include/trace/events/power.h
include/trace/events/sched.h
include/trace/events/timer.h
include/trace/events/tlb.h
include/trace/events/workqueue.h
include/trace/syscall.h
include/uapi/asm-generic/bitsperlong.h
include/uapi/asm-generic/bpf_perf_event.h
include/uapi/asm-generic/errno-base.h
include/uapi/asm-generic/errno.h
include/uapi/asm-generic/fcntl.h
include/uapi/asm-generic/hugetlb_encode.h
include/uapi/asm-generic/int-ll64.h
include/uapi/asm-generic/ioctl.h
include/uapi/asm-generic/ioctls.h
include/uapi/asm-generic/ipcbuf.h
include/uapi/asm-generic/mman-common.h
include/uapi/asm-generic/mman.h
include/uapi/asm-generic/param.h
include/uapi/asm-generic/poll.h
include/uapi/asm-generic/posix_types.h
include/uapi/asm-generic/resource.h
include/uapi/asm-generic/shmbuf.h
include/uapi/asm-generic/siginfo.h
include/uapi/asm-generic/signal-defs.h
include/uapi/asm-generic/socket.h
include/uapi/asm-generic/sockios.h
include/uapi/asm-generic/termbits.h
include/uapi/asm-generic/termios.h
include/uapi/asm-generic/types.h
include/uapi/linux/aio_abi.h
include/uapi/linux/apm_bios.h
include/uapi/linux/audit.h
include/uapi/linux/auxvec.h
include/uapi/linux/binfmts.h
include/uapi/linux/blkzoned.h
include/uapi/linux/bpf.h
include/uapi/linux/bpf_common.h
include/uapi/linux/bpf_perf_event.h
include/uapi/linux/bsg.h
include/uapi/linux/byteorder/little_endian.h
include/uapi/linux/capability.h
include/uapi/linux/cgroupstats.h
include/uapi/linux/const.h
include/uapi/linux/dqblk_xfs.h
include/uapi/linux/edd.h
include/uapi/linux/elf-em.h
include/uapi/linux/elf.h
include/uapi/linux/errno.h
include/uapi/linux/ethtool.h
include/uapi/linux/eventpoll.h
include/uapi/linux/fcntl.h
include/uapi/linux/fib_rules.h
include/uapi/linux/filter.h
include/uapi/linux/fs.h
include/uapi/linux/gen_stats.h
include/uapi/linux/hdlc/ioctl.h
include/uapi/linux/icmpv6.h
include/uapi/linux/if.h
include/uapi/linux/if_addr.h
include/uapi/linux/if_arp.h
include/uapi/linux/if_bonding.h
include/uapi/linux/if_ether.h
include/uapi/linux/if_link.h
include/uapi/linux/if_packet.h
include/uapi/linux/if_vlan.h
include/uapi/linux/in.h
include/uapi/linux/in6.h
include/uapi/linux/ioctl.h
include/uapi/linux/ipc.h
include/uapi/linux/ipv6.h
include/uapi/linux/irqnr.h
include/uapi/linux/kcov.h include/uapi/linux/kcov.h
include/uapi/linux/kd.h
include/uapi/linux/kdev_t.h
include/uapi/linux/kernel.h
include/uapi/linux/kexec.h
include/uapi/linux/kvm_para.h
include/uapi/linux/libc-compat.h
include/uapi/linux/limits.h
include/uapi/linux/magic.h
include/uapi/linux/major.h
include/uapi/linux/mdio.h
include/uapi/linux/membarrier.h
include/uapi/linux/mempolicy.h
include/uapi/linux/mii.h
include/uapi/linux/mman.h
include/uapi/linux/neighbour.h
include/uapi/linux/net.h
include/uapi/linux/net_tstamp.h
include/uapi/linux/netdevice.h
include/uapi/linux/netfilter.h
include/uapi/linux/netfilter/nf_tables.h
include/uapi/linux/netlink.h
include/uapi/linux/openat2.h
include/uapi/linux/param.h
include/uapi/linux/pci.h
include/uapi/linux/pci_regs.h
include/uapi/linux/perf_event.h
include/uapi/linux/personality.h
include/uapi/linux/pkt_cls.h
include/uapi/linux/pkt_sched.h
include/uapi/linux/poll.h
include/uapi/linux/posix_types.h
include/uapi/linux/ptrace.h
include/uapi/linux/quota.h
include/uapi/linux/random.h
include/uapi/linux/reboot.h
include/uapi/linux/resource.h
include/uapi/linux/rseq.h
include/uapi/linux/rtc.h
include/uapi/linux/rtnetlink.h
include/uapi/linux/sched.h
include/uapi/linux/sched/types.h
include/uapi/linux/screen_info.h
include/uapi/linux/seccomp.h
include/uapi/linux/securebits.h
include/uapi/linux/sem.h
include/uapi/linux/shm.h
include/uapi/linux/signal.h
include/uapi/linux/snmp.h
include/uapi/linux/socket.h
include/uapi/linux/sockios.h
include/uapi/linux/stat.h
include/uapi/linux/stddef.h
include/uapi/linux/string.h
include/uapi/linux/swab.h
include/uapi/linux/sysctl.h
include/uapi/linux/sysinfo.h
include/uapi/linux/taskstats.h
include/uapi/linux/tcp.h
include/uapi/linux/termios.h
include/uapi/linux/time.h
include/uapi/linux/time_types.h
include/uapi/linux/timex.h
include/uapi/linux/tty.h
include/uapi/linux/tty_flags.h
include/uapi/linux/types.h
include/uapi/linux/udp.h
include/uapi/linux/uio.h
include/uapi/linux/unistd.h
include/uapi/linux/usb/audio.h include/uapi/linux/usb/audio.h
include/uapi/linux/usb/cdc.h include/uapi/linux/usb/cdc.h
include/uapi/linux/usb/ch11.h include/uapi/linux/usb/ch11.h
include/uapi/linux/usb/ch9.h include/uapi/linux/usb/ch9.h
include/uapi/linux/usb/charger.h include/uapi/linux/usb/charger.h
include/uapi/linux/usbdevice_fs.h include/uapi/linux/usbdevice_fs.h
include/uapi/linux/utsname.h
include/uapi/linux/uuid.h
include/uapi/linux/vt.h
include/uapi/linux/wait.h
include/uapi/linux/xfrm.h
include/uapi/video/edid.h
include/vdso/bits.h
include/vdso/clocksource.h
include/vdso/const.h
include/vdso/jiffies.h
include/vdso/ktime.h
include/vdso/limits.h
include/vdso/math64.h
include/vdso/time.h
include/vdso/time32.h
include/vdso/time64.h
include/video/edid.h
include/video/vga.h
kernel/irq/debug.h
kernel/irq/internals.h
kernel/irq/settings.h
kernel/locking/lock_events.h
kernel/locking/lock_events_list.h
kernel/locking/mutex.h
kernel/sched/autogroup.h
kernel/sched/cpudeadline.h
kernel/sched/cpupri.h
kernel/sched/features.h
kernel/sched/sched.h
kernel/sched/stats.h
kernel/smpboot.h
kernel/time/ntp_internal.h
kernel/time/tick-internal.h
kernel/time/tick-sched.h
kernel/time/timekeeping.h
kernel/time/timekeeping_internal.h
kernel/workqueue_internal.h
lib/crc32defs.h
lib/kstrtox.h
mm/internal.h
mm/slab.h

View File

@ -15,310 +15,6 @@
const struct attribute_group pci_dev_acpi_attr_group; const struct attribute_group pci_dev_acpi_attr_group;
#include <linux/cpuhotplug.h>
int __cpuhp_setup_state(enum cpuhp_state state,const char * name,bool invoke,int (* startup)(unsigned int cpu),int (* teardown)(unsigned int cpu),bool multi_instance)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/timekeeper_internal.h>
void update_vsyscall(struct timekeeper * tk)
{
lx_emul_trace(__func__);
}
#include <linux/clocksource.h>
void clocksource_arch_init(struct clocksource * cs)
{
lx_emul_trace(__func__);
}
#include <linux/sched/signal.h>
void ignore_signals(struct task_struct * t)
{
lx_emul_trace(__func__);
}
#include <linux/sched/loadavg.h>
void calc_global_load(void)
{
lx_emul_trace(__func__);
}
#include <linux/kernel_stat.h>
void account_process_tick(struct task_struct * p,int user_tick)
{
lx_emul_trace(__func__);
}
#include <linux/delay.h>
unsigned long lpj_fine = 0;
#include <linux/rcupdate.h>
void rcu_sched_clock_irq(int user)
{
lx_emul_trace(__func__);
}
#include <linux/sysfs.h>
int sysfs_create_bin_file(struct kobject * kobj,const struct bin_attribute * attr)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/sysfs.h>
int sysfs_create_dir_ns(struct kobject * kobj,const void * ns)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/sysfs.h>
int sysfs_create_file_ns(struct kobject * kobj,const struct attribute * attr,const void * ns)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/sysfs.h>
int sysfs_create_groups(struct kobject * kobj,const struct attribute_group ** groups)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/sysfs.h>
int sysfs_create_group(struct kobject * kobj,const struct attribute_group * grp)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/sysfs.h>
int sysfs_create_link(struct kobject * kobj,struct kobject * target,const char * name)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/sysfs.h>
void sysfs_delete_link(struct kobject * kobj,struct kobject * targ,const char * name)
{
lx_emul_trace(__func__);
}
#include <linux/sysfs.h>
void sysfs_remove_link(struct kobject * kobj,const char * name)
{
lx_emul_trace(__func__);
}
#include <linux/sysfs.h>
void sysfs_remove_file_ns(struct kobject * kobj,const struct attribute * attr,const void * ns)
{
lx_emul_trace(__func__);
}
#include <linux/sysfs.h>
void sysfs_remove_groups(struct kobject * kobj,const struct attribute_group ** groups)
{
lx_emul_trace(__func__);
}
#include <linux/sysfs.h>
void sysfs_remove_dir(struct kobject * kobj)
{
lx_emul_trace(__func__);
}
#include <linux/sysfs.h>
void sysfs_remove_bin_file(struct kobject * kobj,const struct bin_attribute * attr)
{
lx_emul_trace(__func__);
}
#include <linux/kernfs.h>
void kernfs_get(struct kernfs_node * kn)
{
lx_emul_trace(__func__);
}
#include <linux/kernfs.h>
void kernfs_put(struct kernfs_node * kn)
{
lx_emul_trace(__func__);
}
#include <linux/kobject.h>
int kobject_uevent(struct kobject * kobj,enum kobject_action action)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/random.h>
int __must_check get_random_bytes_arch(void * buf,int nbytes)
{
lx_emul_trace(__func__);
printk("%s: leaving buffer unmodified!\n", __func__);
return 0;
}
#include <linux/random.h>
void get_random_bytes(void * buf,int nbytes)
{
lx_emul_trace(__func__);
printk("%s: leaving buffer unmodified!\n", __func__);
}
#include <linux/random.h>
int add_random_ready_callback(struct random_ready_callback * rdy)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/random.h>
void add_device_randomness(const void * buf,unsigned int size)
{
lx_emul_trace(__func__);
}
#include <linux/random.h>
void add_interrupt_randomness(int irq,int irq_flags)
{
lx_emul_trace(__func__);
}
extern bool irq_wait_for_poll(struct irq_desc * desc);
bool irq_wait_for_poll(struct irq_desc * desc)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/irq.h>
void note_interrupt(struct irq_desc * desc,irqreturn_t action_ret)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/fs.h>
int __register_chrdev(unsigned int major,unsigned int baseminor,unsigned int count,const char * name,const struct file_operations * fops)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/fs.h>
int register_chrdev_region(dev_t from,unsigned count,const char * name)
{
lx_emul_trace(__func__);
return 0;
}
extern void register_handler_proc(unsigned int irq,struct irqaction * action);
void register_handler_proc(unsigned int irq,struct irqaction * action)
{
lx_emul_trace(__func__);
}
extern void register_irq_proc(unsigned int irq,struct irq_desc * desc);
void register_irq_proc(unsigned int irq,struct irq_desc * desc)
{
lx_emul_trace(__func__);
}
#include <linux/cdev.h>
void cdev_init(struct cdev * cdev,const struct file_operations * fops)
{
lx_emul_trace(__func__);
}
#include <linux/cdev.h>
int cdev_add(struct cdev * p,dev_t dev,unsigned count)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/cdev.h>
void cdev_del(struct cdev * p)
{
lx_emul_trace(__func__);
}
#include <linux/syscore_ops.h> #include <linux/syscore_ops.h>
@ -328,199 +24,12 @@ void register_syscore_ops(struct syscore_ops * ops)
} }
#include <linux/proc_fs.h>
struct proc_dir_entry { int dummy; };
struct proc_dir_entry * proc_create_seq_private(const char * name,umode_t mode,struct proc_dir_entry * parent,const struct seq_operations * ops,unsigned int state_size,void * data)
{
static struct proc_dir_entry ret;
lx_emul_trace(__func__);
return &ret;
}
#include <linux/property.h> #include <linux/property.h>
int software_node_notify(struct device * dev,unsigned long action) struct device_driver;
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/utsname.h> struct kobj_uevent_env;
#include <linux/user_namespace.h>
struct user_namespace init_user_ns;
struct uts_namespace init_uts_ns;
/*
* linux/seq_file.h depends on user_namespace being defined, add
* all dummies pulling in this header below here
*/
#include <linux/seq_file.h>
void seq_vprintf(struct seq_file * m,const char * f,va_list args)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/vt_kern.h>
void unblank_screen(void)
{
lx_emul_trace_and_stop(__func__);
}
extern void pci_allocate_vc_save_buffers(struct pci_dev * dev);
void pci_allocate_vc_save_buffers(struct pci_dev * dev)
{
lx_emul_trace(__func__);
}
extern void pci_vpd_init(struct pci_dev * dev);
void pci_vpd_init(struct pci_dev * dev)
{
lx_emul_trace(__func__);
}
extern int pci_proc_attach_device(struct pci_dev * dev);
int pci_proc_attach_device(struct pci_dev * dev)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/kernel.h>
bool parse_option_str(const char * str,const char * option)
{
lx_emul_trace(__func__);
return false;
}
extern bool pat_enabled(void);
bool pat_enabled(void)
{
lx_emul_trace(__func__);
return false;
}
#include <linux/mm.h>
bool is_vmalloc_addr(const void * x)
{
lx_emul_trace(__func__);
return false;
}
unsigned long init_stack[THREAD_SIZE / sizeof(unsigned long)];
extern int pci_dev_specific_acs_enabled(struct pci_dev * dev,u16 acs_flags);
int pci_dev_specific_acs_enabled(struct pci_dev * dev,u16 acs_flags)
{
lx_emul_trace(__func__);
return 0;
}
extern int pci_dev_specific_disable_acs_redir(struct pci_dev * dev);
int pci_dev_specific_disable_acs_redir(struct pci_dev * dev)
{
lx_emul_trace(__func__);
return 0;
}
extern int pci_dev_specific_enable_acs(struct pci_dev * dev);
int pci_dev_specific_enable_acs(struct pci_dev * dev)
{
lx_emul_trace(__func__);
return 0;
}
extern int pci_dev_specific_reset(struct pci_dev * dev,int probe);
int pci_dev_specific_reset(struct pci_dev * dev,int probe)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/pci.h>
void pci_fixup_device(enum pci_fixup_pass pass,struct pci_dev * dev)
{
lx_emul_trace(__func__);
}
int acpi_platform_notify(struct device *dev, enum kobject_action action)
{
lx_emul_trace(__func__);
return 0;
}
int pci_acpi_program_hp_params(struct pci_dev *dev)
{
lx_emul_trace(__func__);
return 0;
}
bool acpi_driver_match_device(struct device *dev, const struct device_driver *drv)
{
lx_emul_trace(__func__);
return false;
}
bool is_acpi_device_node(const struct fwnode_handle *fwnode)
{
lx_emul_trace(__func__);
return false;
}
enum dev_dma_attr acpi_get_dma_attr(struct acpi_device *adev)
{
lx_emul_trace_and_stop(__func__);
}
int acpi_device_uevent_modalias(struct device *dev, struct kobj_uevent_env *event)
{
lx_emul_trace_and_stop(__func__);
}
int acpi_dma_configure_id(struct device *dev, enum dev_dma_attr attr, const u32 *input_id)
{
lx_emul_trace_and_stop(__func__);
}
int acpi_device_modalias(struct device *device, char * x, int y)
{
lx_emul_trace_and_stop(__func__);
}
bool pciehp_is_native(struct pci_dev *bridge) bool pciehp_is_native(struct pci_dev *bridge)
@ -528,6 +37,7 @@ bool pciehp_is_native(struct pci_dev *bridge)
lx_emul_trace_and_stop(__func__); lx_emul_trace_and_stop(__func__);
} }
#include <linux/pci.h>
struct irq_domain *pci_host_bridge_acpi_msi_domain(struct pci_bus *bus) struct irq_domain *pci_host_bridge_acpi_msi_domain(struct pci_bus *bus)
{ {
@ -536,16 +46,6 @@ struct irq_domain *pci_host_bridge_acpi_msi_domain(struct pci_bus *bus)
} }
typedef void * acpi_handle;
union acpi_object *acpi_evaluate_dsm(acpi_handle handle, const guid_t *guid,
u64 rev, u64 func, union acpi_object *argv4)
{
lx_emul_trace(__func__);
return NULL;
}
int usb_acpi_register(void) int usb_acpi_register(void)
{ {
lx_emul_trace(__func__); lx_emul_trace(__func__);

View File

@ -1,28 +1,12 @@
/* /*
* \brief Dummy definitions of Linux Kernel functions * \brief Dummy definitions of Linux Kernel functions
* \author Automatically generated file - do no edit * \author Automatically generated file - do no edit
* \date 2022-02-03 * \date 2022-05-06
*/ */
#include <lx_emul.h> #include <lx_emul.h>
#include <linux/bitops.h>
unsigned int __sw_hweight32(unsigned int w)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/bitops.h>
unsigned long __sw_hweight64(__u64 w)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/proc_fs.h> #include <linux/proc_fs.h>
void * PDE_DATA(const struct inode * inode) void * PDE_DATA(const struct inode * inode)
@ -47,14 +31,6 @@ const char * __clk_get_name(const struct clk * clk)
} }
#include <linux/gfp.h>
unsigned long __get_free_pages(gfp_t gfp_mask,unsigned int order)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/cred.h> #include <linux/cred.h>
void __put_cred(struct cred * cred) void __put_cred(struct cred * cred)
@ -174,14 +150,6 @@ bool file_ns_capable(const struct file * file,struct user_namespace * ns,int cap
} }
#include <linux/gfp.h>
void free_pages(unsigned long addr,unsigned int order)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/property.h> #include <linux/property.h>
void fwnode_remove_software_node(struct fwnode_handle * fwnode) void fwnode_remove_software_node(struct fwnode_handle * fwnode)
@ -309,6 +277,14 @@ int kill_pid_usb_asyncio(int sig,int errno,sigval_t addr,struct pid * pid,const
} }
#include <linux/slab.h>
void kmem_cache_destroy(struct kmem_cache * s)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/kobject.h> #include <linux/kobject.h>
int kobject_synth_uevent(struct kobject * kobj,const char * buf,size_t count) int kobject_synth_uevent(struct kobject * kobj,const char * buf,size_t count)
@ -333,13 +309,6 @@ unsigned long long memparse(const char * ptr,char ** retptr)
} }
extern void native_io_delay(void);
void native_io_delay(void)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/irq.h> #include <linux/irq.h>
struct irq_chip no_irq_chip; struct irq_chip no_irq_chip;
@ -361,6 +330,14 @@ loff_t noop_llseek(struct file * file,loff_t offset,int whence)
} }
#include <linux/irq.h>
void note_interrupt(struct irq_desc * desc,irqreturn_t action_ret)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/moduleparam.h> #include <linux/moduleparam.h>
int param_set_copystring(const char * val,const struct kernel_param * kp) int param_set_copystring(const char * val,const struct kernel_param * kp)
@ -524,14 +501,6 @@ int remap_pfn_range(struct vm_area_struct * vma,unsigned long addr,unsigned long
} }
#include <linux/sched.h>
void sched_set_fifo(struct task_struct * p)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/seq_file.h> #include <linux/seq_file.h>
void seq_printf(struct seq_file * m,const char * f,...) void seq_printf(struct seq_file * m,const char * f,...)
@ -577,46 +546,6 @@ void synchronize_srcu(struct srcu_struct * ssp)
} }
#include <linux/sysfs.h>
int sysfs_emit(char * buf,const char * fmt,...)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/sysfs.h>
int sysfs_emit_at(char * buf,int at,const char * fmt,...)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/sysfs.h>
void sysfs_notify(struct kobject * kobj,const char * dir,const char * attr)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/sysfs.h>
bool sysfs_remove_file_self(struct kobject * kobj,const struct attribute * attr)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/sysfs.h>
void sysfs_remove_group(struct kobject * kobj,const struct attribute_group * grp)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/task_work.h> #include <linux/task_work.h>
int task_work_add(struct task_struct * task,struct callback_head * work,enum task_work_notify_mode notify) int task_work_add(struct task_struct * task,struct callback_head * work,enum task_work_notify_mode notify)
@ -660,10 +589,3 @@ void wake_q_add_safe(struct wake_q_head * head,struct task_struct * task)
lx_emul_trace_and_stop(__func__); lx_emul_trace_and_stop(__func__);
} }
#include <linux/slab.h>
void kmem_cache_destroy(struct kmem_cache * s)
{
lx_emul_trace_and_stop(__func__);
}

View File

@ -12,200 +12,3 @@
*/ */
#include <lx_emul.h> #include <lx_emul.h>
#include <linux/slab.h>
#include <lx_emul/alloc.h>
#include <lx_emul/io_mem.h>
#include <asm-generic/delay.h>
#include <linux/delay.h>
void __const_udelay(unsigned long xloops)
{
unsigned long usecs = xloops / 0x10C7UL;
if (usecs < 100)
lx_emul_time_udelay(usecs);
else
usleep_range(usecs, usecs * 10);
}
void __udelay(unsigned long usecs)
{
lx_emul_time_udelay(usecs);
}
#include <linux/cpumask.h>
atomic_t __num_online_cpus = ATOMIC_INIT(1);
#include <linux/dma-mapping.h>
dma_addr_t dma_map_page_attrs(struct device * dev,
struct page * page,
size_t offset,
size_t size,
enum dma_data_direction dir,
unsigned long attrs)
{
dma_addr_t const dma_addr = page_to_phys(page);
unsigned long const virt_addr = (unsigned long)page_to_virt(page);
lx_emul_mem_cache_clean_invalidate((void *)(virt_addr + offset), size);
return dma_addr + offset;
}
#include <linux/dmapool.h>
struct dma_pool { size_t size; };
void * dma_pool_alloc(struct dma_pool * pool, gfp_t mem_flags, dma_addr_t * handle)
{
void * ret =
lx_emul_mem_alloc_aligned_uncached(pool->size, PAGE_SIZE);
*handle = lx_emul_mem_dma_addr(ret);
return ret;
}
struct dma_pool * dma_pool_create(const char * name,
struct device * dev,
size_t size,
size_t align,
size_t boundary)
{
struct dma_pool * pool = kmalloc(sizeof(struct dma_pool), GFP_KERNEL);
pool->size = size;
return pool;
}
void dma_pool_destroy(struct dma_pool * pool)
{
kfree(pool);
}
void dma_pool_free(struct dma_pool * pool,void * vaddr,dma_addr_t dma)
{
lx_emul_mem_free(vaddr);
}
#include <linux/dma-mapping.h>
int dma_supported(struct device * dev,u64 mask)
{
lx_emul_trace(__func__);
return 1;
}
#include <linux/dma-mapping.h>
void dma_unmap_page_attrs(struct device * dev,
dma_addr_t addr,
size_t size,
enum dma_data_direction dir,
unsigned long attrs)
{
unsigned long const virt_addr = lx_emul_mem_virt_addr((void*)addr);
if (!virt_addr)
return;
if (dir == DMA_FROM_DEVICE)
lx_emul_mem_cache_invalidate((void *)virt_addr, size);
}
#include <linux/slab.h>
void * kmalloc_order(size_t size, gfp_t flags, unsigned int order)
{
return kmalloc(size, flags);
}
#include <linux/fs.h>
#include <linux/mount.h>
#include <linux/slab.h>
int simple_pin_fs(struct file_system_type * type, struct vfsmount ** mount, int * count)
{
*mount = kmalloc(sizeof(struct vfsmount), GFP_KERNEL);
return 0;
}
#include <linux/fs.h>
void simple_release_fs(struct vfsmount ** mount,int * count)
{
kfree(*mount);
}
#include <linux/fs.h>
struct inode * alloc_anon_inode(struct super_block * s)
{
return kmalloc(sizeof(struct inode), GFP_KERNEL);
}
#include <linux/interrupt.h>
void tasklet_setup(struct tasklet_struct * t,
void (* callback)(struct tasklet_struct *))
{
t->next = NULL;
t->state = 0;
atomic_set(&t->count, 0);
t->callback = callback;
t->use_callback = true;
t->data = 0;
}
void __tasklet_schedule(struct tasklet_struct * t)
{
if (test_and_clear_bit(TASKLET_STATE_SCHED, &t->state))
t->callback(t);
}
void __tasklet_hi_schedule(struct tasklet_struct * t)
{
if (test_and_clear_bit(TASKLET_STATE_SCHED, &t->state))
t->callback(t);
}
#include <linux/rcupdate.h>
void call_rcu(struct rcu_head * head,rcu_callback_t func)
{
lx_emul_trace(__func__);
func(head);
}
#include <asm-generic/logic_io.h>
void __iomem * ioremap(resource_size_t phys_addr, unsigned long size)
{
return lx_emul_io_mem_map(phys_addr, size);
}
#include <asm-generic/logic_io.h>
void iounmap(volatile void __iomem * addr)
{
(void)addr;
}

View File

@ -1,14 +1,16 @@
arch/x86/include/asm/checksum_32.h arch/x86/include/asm/checksum_32.h
arch/x86/include/asm/cmpxchg_32.h arch/x86/include/asm/cmpxchg_32.h
arch/x86/include/asm/numa_32.h
arch/x86/include/asm/page_32.h arch/x86/include/asm/page_32.h
arch/x86/include/asm/page_32_types.h arch/x86/include/asm/page_32_types.h
arch/x86/include/asm/pgtable-2level_types.h arch/x86/include/asm/pgtable-2level_types.h
arch/x86/include/asm/pgtable_32_areas.h arch/x86/include/asm/pgtable_32_areas.h
arch/x86/include/asm/pgtable_32_types.h arch/x86/include/asm/pgtable_32_types.h
arch/x86/include/asm/special_insns.h
arch/x86/include/asm/uaccess_32.h arch/x86/include/asm/uaccess_32.h
arch/x86/include/asm/user_32.h arch/x86/include/asm/user_32.h
arch/x86/include/uapi/asm/posix_types_32.h arch/x86/include/uapi/asm/posix_types_32.h
include/asm-generic/asm-prototypes.h
include/asm-generic/bitops/fls64.h include/asm-generic/bitops/fls64.h
include/asm-generic/pgtable-nopmd.h include/asm-generic/pgtable-nopmd.h
include/asm-generic/pgtable-nopud.h include/asm-generic/pgtable-nopud.h

View File

@ -1,3 +1,5 @@
arch/x86/lib/delay.c
arch/x86/lib/hweight.S
arch/x86/pci/legacy.c arch/x86/pci/legacy.c
drivers/base/bus.c drivers/base/bus.c
drivers/base/class.c drivers/base/class.c

View File

@ -2,15 +2,11 @@ arch/x86/include/asm/atomic64_64.h
arch/x86/include/asm/checksum_64.h arch/x86/include/asm/checksum_64.h
arch/x86/include/asm/cmpxchg_64.h arch/x86/include/asm/cmpxchg_64.h
arch/x86/include/asm/kaslr.h arch/x86/include/asm/kaslr.h
arch/x86/include/asm/page_64.h
arch/x86/include/asm/page_64_types.h arch/x86/include/asm/page_64_types.h
arch/x86/include/asm/pgtable_64_types.h arch/x86/include/asm/pgtable_64_types.h
arch/x86/include/asm/sparsemem.h arch/x86/include/asm/sparsemem.h
arch/x86/include/asm/string_64.h arch/x86/include/asm/string_64.h
arch/x86/include/asm/uaccess_64.h
arch/x86/include/asm/user_64.h arch/x86/include/asm/user_64.h
arch/x86/include/uapi/asm/posix_types_64.h arch/x86/include/uapi/asm/posix_types_64.h
arch/x86/include/uapi/asm/vsyscall.h arch/x86/include/uapi/asm/vsyscall.h
include/asm-generic/div64.h include/asm-generic/div64.h
kernel/irq/irqdomain.c
kernel/time/tick-broadcast.c

View File

@ -1,3 +1,5 @@
arch/x86/lib/delay.c
arch/x86/lib/hweight.S
arch/x86/pci/legacy.c arch/x86/pci/legacy.c
drivers/base/bus.c drivers/base/bus.c
drivers/base/class.c drivers/base/class.c

View File

@ -8,7 +8,6 @@ LIBS := base pc_lx_emul
INC_DIR += $(REL_PRG_DIR) INC_DIR += $(REL_PRG_DIR)
SRC_CC += main.cc SRC_CC += main.cc
SRC_CC += misc.cc SRC_CC += misc.cc
SRC_CC += time.cc
SRC_CC += lx_emul/shared_dma_buffer.cc SRC_CC += lx_emul/shared_dma_buffer.cc
SRC_C += dummies.c SRC_C += dummies.c
SRC_C += lx_emul.c SRC_C += lx_emul.c
@ -16,6 +15,11 @@ SRC_C += $(notdir $(wildcard $(REL_PRG_DIR)/generated_dummies.c))
SRC_C += common_dummies.c SRC_C += common_dummies.c
SRC_C += lx_emul/spec/x86/pci.c SRC_C += lx_emul/spec/x86/pci.c
SRC_C += lx_emul/usb.c SRC_C += lx_emul/usb.c
SRC_C += lx_emul/shadow/drivers/char/random.c
SRC_C += lx_emul/shadow/lib/kobject_uevent.c
vpath %.c $(REP_DIR)/src/lib/pc
vpath %.cc $(REP_DIR)/src/lib/pc
vpath %.c $(REL_PRG_DIR) vpath %.c $(REL_PRG_DIR)
vpath %.cc $(REL_PRG_DIR) vpath %.cc $(REL_PRG_DIR)

View File

@ -1,25 +0,0 @@
/*
* \brief Lx_emul udelay function for very short delays
* \author Stefan Kalkowski
* \date 2021-07-10
*/
/*
* Copyright (C) 2021 Genode Labs GmbH
*
* This file is distributed under the terms of the GNU General Public License
* version 2.
*/
#include <base/log.h>
#include <lx_kit/env.h>
extern "C" void lx_emul_time_udelay(unsigned long usec);
extern "C" void lx_emul_time_udelay(unsigned long usec)
{
if (usec > 100)
Genode::error("Cannot delay that long ", usec, " microseconds");
unsigned long long start = Lx_kit::env().timer.curr_time().trunc_to_plain_us().value;
while (Lx_kit::env().timer.curr_time().trunc_to_plain_us().value < (start + usec)) { ; }
}

View File

@ -46,3 +46,336 @@ const struct trace_print_flags pageflag_names[] = { {0,NULL}};
#include <linux/kernel_stat.h> #include <linux/kernel_stat.h>
struct kernel_stat kstat; struct kernel_stat kstat;
#include <linux/delay.h>
/* support for arch/x86/lib/delay.c, normally defined in init/main.c */
unsigned long loops_per_jiffy = (1<<12);
#include <asm/processor.h>
/*
* Early_identify_cpu() in linux sets this up normally, used by drm_cache
* as well as arch/x86/lib/delay.c.
*/
struct cpuinfo_x86 boot_cpu_data =
{
.x86_clflush_size = (sizeof(void*) == 8) ? 64 : 32,
.x86_cache_alignment = (sizeof(void*) == 8) ? 64 : 32,
.x86_phys_bits = (sizeof(void*) == 8) ? 36 : 32,
.x86_virt_bits = (sizeof(void*) == 8) ? 48 : 32
};
unsigned long init_stack[THREAD_SIZE / sizeof(unsigned long)];
#include <linux/delay.h>
unsigned long lpj_fine = 0;
/*
* Generate_dummies.c will otherwise pull in <linux/rcutree.h>
* that clashes with rcutiny.h.
*/
void rcu_barrier(void)
{
lx_emul_trace(__func__);
}
#include <linux/cpuhotplug.h>
int __cpuhp_setup_state(enum cpuhp_state state,const char * name,bool invoke,int (* startup)(unsigned int cpu),int (* teardown)(unsigned int cpu),bool multi_instance)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/timekeeper_internal.h>
void update_vsyscall(struct timekeeper * tk)
{
lx_emul_trace(__func__);
}
#include <linux/clocksource.h>
void clocksource_arch_init(struct clocksource * cs)
{
lx_emul_trace(__func__);
}
#include <linux/sched/signal.h>
void ignore_signals(struct task_struct * t)
{
lx_emul_trace(__func__);
}
#include <linux/sched/loadavg.h>
void calc_global_load(void)
{
lx_emul_trace(__func__);
}
#include <linux/kernel_stat.h>
void account_process_tick(struct task_struct * p,int user_tick)
{
lx_emul_trace(__func__);
}
#include <linux/rcupdate.h>
void rcu_sched_clock_irq(int user)
{
lx_emul_trace(__func__);
}
#include <linux/kernfs.h>
void kernfs_get(struct kernfs_node * kn)
{
lx_emul_trace(__func__);
}
void kernfs_put(struct kernfs_node * kn)
{
lx_emul_trace(__func__);
}
#include <linux/random.h>
int add_random_ready_callback(struct random_ready_callback * rdy)
{
lx_emul_trace(__func__);
return 0;
}
void add_device_randomness(const void * buf,unsigned int size)
{
lx_emul_trace(__func__);
}
#include <linux/random.h>
void add_interrupt_randomness(int irq,int irq_flags)
{
lx_emul_trace(__func__);
}
extern bool irq_wait_for_poll(struct irq_desc * desc);
bool irq_wait_for_poll(struct irq_desc * desc)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/fs.h>
int __register_chrdev(unsigned int major,unsigned int baseminor,unsigned int count,const char * name,const struct file_operations * fops)
{
lx_emul_trace(__func__);
return 0;
}
int register_chrdev_region(dev_t from,unsigned count,const char * name)
{
lx_emul_trace(__func__);
return 0;
}
extern void register_handler_proc(unsigned int irq,struct irqaction * action);
void register_handler_proc(unsigned int irq,struct irqaction * action)
{
lx_emul_trace(__func__);
}
extern void register_irq_proc(unsigned int irq,struct irq_desc * desc);
void register_irq_proc(unsigned int irq,struct irq_desc * desc)
{
lx_emul_trace(__func__);
}
#include <linux/cdev.h>
void cdev_init(struct cdev * cdev,const struct file_operations * fops)
{
lx_emul_trace(__func__);
}
int cdev_add(struct cdev * p,dev_t dev,unsigned count)
{
lx_emul_trace(__func__);
return 0;
}
void cdev_del(struct cdev * p)
{
lx_emul_trace(__func__);
}
#include <linux/proc_fs.h>
struct proc_dir_entry { int dummy; };
struct proc_dir_entry * proc_create_seq_private(const char * name,umode_t mode,struct proc_dir_entry * parent,const struct seq_operations * ops,unsigned int state_size,void * data)
{
static struct proc_dir_entry ret;
lx_emul_trace(__func__);
return &ret;
}
struct proc_dir_entry * proc_create_net_data(const char * name,umode_t mode,struct proc_dir_entry * parent,const struct seq_operations * ops,unsigned int state_size,void * data)
{
static struct proc_dir_entry _proc_dir_entry;
lx_emul_trace(__func__);
return &_proc_dir_entry;
}
#include <linux/utsname.h>
#include <linux/user_namespace.h>
struct user_namespace init_user_ns;
struct uts_namespace init_uts_ns;
/*
* linux/seq_file.h depends on user_namespace being defined, add
* all dummies pulling in this header below here
*/
#include <linux/seq_file.h>
void seq_vprintf(struct seq_file * m,const char * f,va_list args)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/property.h>
int software_node_notify(struct device * dev,unsigned long action)
{
lx_emul_trace(__func__);
return 0;
}
extern void pci_allocate_vc_save_buffers(struct pci_dev * dev);
void pci_allocate_vc_save_buffers(struct pci_dev * dev)
{
lx_emul_trace(__func__);
}
extern void pci_vpd_init(struct pci_dev * dev);
void pci_vpd_init(struct pci_dev * dev)
{
lx_emul_trace(__func__);
}
extern int pci_proc_attach_device(struct pci_dev * dev);
int pci_proc_attach_device(struct pci_dev * dev)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/kernel.h>
bool parse_option_str(const char * str,const char * option)
{
lx_emul_trace(__func__);
return false;
}
#include <linux/pci.h>
void pci_fixup_device(enum pci_fixup_pass pass,struct pci_dev * dev)
{
lx_emul_trace(__func__);
}
int pci_disable_link_state(struct pci_dev * pdev,int state)
{
lx_emul_trace(__func__);
return 0;
}
extern int pci_dev_specific_acs_enabled(struct pci_dev * dev,u16 acs_flags);
int pci_dev_specific_acs_enabled(struct pci_dev * dev,u16 acs_flags)
{
lx_emul_trace(__func__);
return 0;
}
extern int pci_dev_specific_disable_acs_redir(struct pci_dev * dev);
int pci_dev_specific_disable_acs_redir(struct pci_dev * dev)
{
lx_emul_trace(__func__);
return 0;
}
extern int pci_dev_specific_enable_acs(struct pci_dev * dev);
int pci_dev_specific_enable_acs(struct pci_dev * dev)
{
lx_emul_trace(__func__);
return 0;
}
extern int pci_dev_specific_reset(struct pci_dev * dev,int probe);
int pci_dev_specific_reset(struct pci_dev * dev,int probe)
{
lx_emul_trace(__func__);
return 0;
}
int pci_acpi_program_hp_params(struct pci_dev *dev)
{
lx_emul_trace(__func__);
return -ENODEV;
}
extern bool pat_enabled(void);
bool pat_enabled(void)
{
/* used for mmap WC check */
lx_emul_trace(__func__);
return true;
}

View File

@ -0,0 +1,964 @@
arch/x86/include/asm/acenv.h
arch/x86/include/asm/acpi.h
arch/x86/include/asm/alternative.h
arch/x86/include/asm/apicdef.h
arch/x86/include/asm/arch_hweight.h
arch/x86/include/asm/asm.h
arch/x86/include/asm/atomic.h
arch/x86/include/asm/barrier.h
arch/x86/include/asm/bitops.h
arch/x86/include/asm/bug.h
arch/x86/include/asm/cache.h
arch/x86/include/asm/cacheflush.h
arch/x86/include/asm/checksum.h
arch/x86/include/asm/clocksource.h
arch/x86/include/asm/cmpxchg.h
arch/x86/include/asm/compat.h
arch/x86/include/asm/cpu_entry_area.h
arch/x86/include/asm/cpufeatures.h
arch/x86/include/asm/cpumask.h
arch/x86/include/asm/delay.h
arch/x86/include/asm/desc.h
arch/x86/include/asm/desc_defs.h
arch/x86/include/asm/device.h
arch/x86/include/asm/disabled-features.h
arch/x86/include/asm/div64.h
arch/x86/include/asm/dma.h
arch/x86/include/asm/elf.h
arch/x86/include/asm/emergency-restart.h
arch/x86/include/asm/exec.h
arch/x86/include/asm/extable.h
arch/x86/include/asm/fixmap.h
arch/x86/include/asm/fpu/api.h
arch/x86/include/asm/fpu/types.h
arch/x86/include/asm/fsgsbase.h
arch/x86/include/asm/ftrace.h
arch/x86/include/asm/hardirq.h
arch/x86/include/asm/hw_breakpoint.h
arch/x86/include/asm/hw_irq.h
arch/x86/include/asm/intel_ds.h
arch/x86/include/asm/invpcid.h
arch/x86/include/asm/irq.h
arch/x86/include/asm/irq_vectors.h
arch/x86/include/asm/irq_work.h
arch/x86/include/asm/irqdomain.h
arch/x86/include/asm/ist.h
arch/x86/include/asm/jailhouse_para.h
arch/x86/include/asm/kdebug.h
arch/x86/include/asm/kgdb.h
arch/x86/include/asm/kprobes.h
arch/x86/include/asm/kvm_para.h
arch/x86/include/asm/linkage.h
arch/x86/include/asm/local.h
arch/x86/include/asm/math_emu.h
arch/x86/include/asm/mem_encrypt.h
arch/x86/include/asm/memtype.h
arch/x86/include/asm/mmu.h
arch/x86/include/asm/mmu_context.h
arch/x86/include/asm/module.h
arch/x86/include/asm/mpspec.h
arch/x86/include/asm/mpspec_def.h
arch/x86/include/asm/msi.h
arch/x86/include/asm/msr-index.h
arch/x86/include/asm/msr.h
arch/x86/include/asm/mwait.h
arch/x86/include/asm/nmi.h
arch/x86/include/asm/nops.h
arch/x86/include/asm/nospec-branch.h
arch/x86/include/asm/numa.h
arch/x86/include/asm/orc_types.h
arch/x86/include/asm/page_64.h
arch/x86/include/asm/page_types.h
arch/x86/include/asm/paravirt.h
arch/x86/include/asm/pci.h
arch/x86/include/asm/pci_x86.h
arch/x86/include/asm/percpu.h
arch/x86/include/asm/perf_event.h
arch/x86/include/asm/pgtable_areas.h
arch/x86/include/asm/pgtable_types.h
arch/x86/include/asm/posix_types.h
arch/x86/include/asm/preempt.h
arch/x86/include/asm/processor-flags.h
arch/x86/include/asm/processor.h
arch/x86/include/asm/proto.h
arch/x86/include/asm/pti.h
arch/x86/include/asm/ptrace.h
arch/x86/include/asm/required-features.h
arch/x86/include/asm/rmwcc.h
arch/x86/include/asm/segment.h
arch/x86/include/asm/set_memory.h
arch/x86/include/asm/shmparam.h
arch/x86/include/asm/signal.h
arch/x86/include/asm/smap.h
arch/x86/include/asm/smp.h
arch/x86/include/asm/stacktrace.h
arch/x86/include/asm/static_call.h
arch/x86/include/asm/string.h
arch/x86/include/asm/syscall_wrapper.h
arch/x86/include/asm/text-patching.h
arch/x86/include/asm/thread_info.h
arch/x86/include/asm/timer.h
arch/x86/include/asm/timex.h
arch/x86/include/asm/tlb.h
arch/x86/include/asm/tlbbatch.h
arch/x86/include/asm/tlbflush.h
arch/x86/include/asm/topology.h
arch/x86/include/asm/trace_clock.h
arch/x86/include/asm/tsc.h
arch/x86/include/asm/uaccess.h
arch/x86/include/asm/uaccess_64.h
arch/x86/include/asm/unistd.h
arch/x86/include/asm/unwind_hints.h
arch/x86/include/asm/user.h
arch/x86/include/asm/user32.h
arch/x86/include/asm/vdso.h
arch/x86/include/asm/vdso/clocksource.h
arch/x86/include/asm/vga.h
arch/x86/include/asm/vmalloc.h
arch/x86/include/asm/vmxfeatures.h
arch/x86/include/asm/word-at-a-time.h
arch/x86/include/asm/x86_init.h
arch/x86/include/uapi/asm/auxvec.h
arch/x86/include/uapi/asm/bitsperlong.h
arch/x86/include/uapi/asm/bootparam.h
arch/x86/include/uapi/asm/byteorder.h
arch/x86/include/uapi/asm/hw_breakpoint.h
arch/x86/include/uapi/asm/ist.h
arch/x86/include/uapi/asm/kvm_para.h
arch/x86/include/uapi/asm/ldt.h
arch/x86/include/uapi/asm/mman.h
arch/x86/include/uapi/asm/msr.h
arch/x86/include/uapi/asm/perf_regs.h
arch/x86/include/uapi/asm/processor-flags.h
arch/x86/include/uapi/asm/ptrace-abi.h
arch/x86/include/uapi/asm/ptrace.h
arch/x86/include/uapi/asm/sembuf.h
arch/x86/include/uapi/asm/shmbuf.h
arch/x86/include/uapi/asm/sigcontext.h
arch/x86/include/uapi/asm/siginfo.h
arch/x86/include/uapi/asm/signal.h
arch/x86/include/uapi/asm/stat.h
arch/x86/include/uapi/asm/swab.h
arch/x86/include/uapi/asm/unistd.h
drivers/base/base.h
drivers/base/power/power.h
drivers/base/trace.h
drivers/pci/pci.h
drivers/pci/pcie/portdrv.h
include/acpi/acbuffer.h
include/acpi/acconfig.h
include/acpi/acexcep.h
include/acpi/acnames.h
include/acpi/acoutput.h
include/acpi/acpi.h
include/acpi/acpi_bus.h
include/acpi/acpi_drivers.h
include/acpi/acpi_io.h
include/acpi/acpi_numa.h
include/acpi/acpiosxf.h
include/acpi/acpixf.h
include/acpi/acrestyp.h
include/acpi/actbl.h
include/acpi/actbl1.h
include/acpi/actbl2.h
include/acpi/actbl3.h
include/acpi/actypes.h
include/acpi/pdc_intel.h
include/acpi/platform/acenv.h
include/acpi/platform/acenvex.h
include/acpi/platform/acgcc.h
include/acpi/platform/acgccex.h
include/acpi/platform/aclinux.h
include/acpi/platform/aclinuxex.h
include/asm-generic/atomic-instrumented.h
include/asm-generic/atomic-long.h
include/asm-generic/barrier.h
include/asm-generic/bitops/const_hweight.h
include/asm-generic/bitops/ext2-atomic-setbit.h
include/asm-generic/bitops/find.h
include/asm-generic/bitops/instrumented-atomic.h
include/asm-generic/bitops/instrumented-lock.h
include/asm-generic/bitops/instrumented-non-atomic.h
include/asm-generic/bitops/le.h
include/asm-generic/bitops/sched.h
include/asm-generic/bitsperlong.h
include/asm-generic/bug.h
include/asm-generic/cacheflush.h
include/asm-generic/compat.h
include/asm-generic/delay.h
include/asm-generic/early_ioremap.h
include/asm-generic/error-injection.h
include/asm-generic/fixmap.h
include/asm-generic/getorder.h
include/asm-generic/int-ll64.h
include/asm-generic/io.h
include/asm-generic/ioctl.h
include/asm-generic/iomap.h
include/asm-generic/irq_regs.h
include/asm-generic/kmap_size.h
include/asm-generic/kprobes.h
include/asm-generic/local64.h
include/asm-generic/logic_io.h
include/asm-generic/mmiowb.h
include/asm-generic/mmu_context.h
include/asm-generic/module.h
include/asm-generic/param.h
include/asm-generic/pci.h
include/asm-generic/pci_iomap.h
include/asm-generic/percpu.h
include/asm-generic/pgtable-nop4d.h
include/asm-generic/resource.h
include/asm-generic/rwonce.h
include/asm-generic/sections.h
include/asm-generic/set_memory.h
include/asm-generic/termios.h
include/asm-generic/tlb.h
include/asm-generic/topology.h
include/asm-generic/unaligned.h
include/crypto/sha1.h
include/linux/acpi.h
include/linux/acpi_iort.h
include/linux/aer.h
include/linux/alarmtimer.h
include/linux/align.h
include/linux/apm_bios.h
include/linux/arch_topology.h
include/linux/assoc_array.h
include/linux/async.h
include/linux/atomic-arch-fallback.h
include/linux/atomic.h
include/linux/audit.h
include/linux/auxvec.h
include/linux/backing-dev-defs.h
include/linux/binfmts.h
include/linux/bio.h
include/linux/bit_spinlock.h
include/linux/bitfield.h
include/linux/bitmap.h
include/linux/bitops.h
include/linux/bitrev.h
include/linux/bits.h
include/linux/blk-cgroup.h
include/linux/blk_types.h
include/linux/blkdev.h
include/linux/bottom_half.h
include/linux/bpf-cgroup.h
include/linux/bpf-netns.h
include/linux/bpf.h
include/linux/bpfptr.h
include/linux/bsg.h
include/linux/bug.h
include/linux/build_bug.h
include/linux/buildid.h
include/linux/bvec.h
include/linux/byteorder/generic.h
include/linux/byteorder/little_endian.h
include/linux/cache.h
include/linux/capability.h
include/linux/cc_platform.h
include/linux/cdev.h
include/linux/cfi.h
include/linux/cgroup-defs.h
include/linux/cgroup.h
include/linux/clk-provider.h
include/linux/clk.h
include/linux/clk/clk-conf.h
include/linux/clockchips.h
include/linux/clocksource.h
include/linux/clocksource_ids.h
include/linux/compat.h
include/linux/compiler-gcc.h
include/linux/compiler.h
include/linux/compiler_attributes.h
include/linux/compiler_types.h
include/linux/completion.h
include/linux/component.h
include/linux/console.h
include/linux/console_struct.h
include/linux/consolemap.h
include/linux/const.h
include/linux/context_tracking.h
include/linux/context_tracking_state.h
include/linux/cpu.h
include/linux/cpufreq.h
include/linux/cpuhotplug.h
include/linux/cpuidle.h
include/linux/cpumask.h
include/linux/cpuset.h
include/linux/crash_core.h
include/linux/crc32.h
include/linux/crc32poly.h
include/linux/cred.h
include/linux/ctype.h
include/linux/dax.h
include/linux/dcache.h
include/linux/debug_locks.h
include/linux/debugfs.h
include/linux/debugobjects.h
include/linux/delay.h
include/linux/delayacct.h
include/linux/delayed_call.h
include/linux/dev_printk.h
include/linux/device.h
include/linux/device/bus.h
include/linux/device/class.h
include/linux/device/driver.h
include/linux/dma-direction.h
include/linux/dma-map-ops.h
include/linux/dma-mapping.h
include/linux/dmapool.h
include/linux/dmi.h
include/linux/dqblk_qtree.h
include/linux/dqblk_v1.h
include/linux/dqblk_v2.h
include/linux/dynamic_debug.h
include/linux/dynamic_queue_limits.h
include/linux/edd.h
include/linux/elevator.h
include/linux/elf-randomize.h
include/linux/elf.h
include/linux/elfcore.h
include/linux/energy_model.h
include/linux/err.h
include/linux/errname.h
include/linux/errno.h
include/linux/error-injection.h
include/linux/errseq.h
include/linux/etherdevice.h
include/linux/ethtool.h
include/linux/eventfd.h
include/linux/export.h
include/linux/fault-inject-usercopy.h
include/linux/fault-inject.h
include/linux/fcntl.h
include/linux/file.h
include/linux/filter.h
include/linux/flex_proportions.h
include/linux/freelist.h
include/linux/freezer.h
include/linux/fs.h
include/linux/fs_context.h
include/linux/fs_types.h
include/linux/ftrace.h
include/linux/ftrace_irq.h
include/linux/fwnode.h
include/linux/genhd.h
include/linux/gfp.h
include/linux/gpio/consumer.h
include/linux/hardirq.h
include/linux/hash.h
include/linux/hashtable.h
include/linux/highmem-internal.h
include/linux/highmem.h
include/linux/highuid.h
include/linux/hrtimer.h
include/linux/hrtimer_defs.h
include/linux/huge_mm.h
include/linux/hugetlb.h
include/linux/hugetlb_inline.h
include/linux/hypervisor.h
include/linux/icmpv6.h
include/linux/idr.h
include/linux/if_arp.h
include/linux/if_ether.h
include/linux/if_link.h
include/linux/if_vlan.h
include/linux/in.h
include/linux/in6.h
include/linux/indirect_call_wrapper.h
include/linux/init.h
include/linux/init_task.h
include/linux/instrumentation.h
include/linux/instrumented.h
include/linux/interrupt.h
include/linux/interval_tree.h
include/linux/io.h
include/linux/iocontext.h
include/linux/iopoll.h
include/linux/ioport.h
include/linux/ioprio.h
include/linux/ipc.h
include/linux/ipv6.h
include/linux/irq.h
include/linux/irq_work.h
include/linux/irqchip.h
include/linux/irqdesc.h
include/linux/irqdomain.h
include/linux/irqflags.h
include/linux/irqhandler.h
include/linux/irqnr.h
include/linux/irqreturn.h
include/linux/jhash.h
include/linux/jiffies.h
include/linux/jump_label.h
include/linux/jump_label_ratelimit.h
include/linux/kallsyms.h
include/linux/kasan-checks.h
include/linux/kasan.h
include/linux/kconfig.h
include/linux/kcsan-checks.h
include/linux/kcsan.h
include/linux/kdebug.h
include/linux/kdev_t.h
include/linux/kern_levels.h
include/linux/kernel.h
include/linux/kernel_read_file.h
include/linux/kernel_stat.h
include/linux/kernfs.h
include/linux/kexec.h
include/linux/key.h
include/linux/kgdb.h
include/linux/klist.h
include/linux/kmemleak.h
include/linux/kmod.h
include/linux/kmsg_dump.h
include/linux/kobject.h
include/linux/kobject_ns.h
include/linux/kprobes.h
include/linux/kref.h
include/linux/kstrtox.h
include/linux/kthread.h
include/linux/ktime.h
include/linux/kvm_para.h
include/linux/latencytop.h
include/linux/limits.h
include/linux/linkage.h
include/linux/linkmode.h
include/linux/list.h
include/linux/list_bl.h
include/linux/list_lru.h
include/linux/list_nulls.h
include/linux/list_sort.h
include/linux/livepatch.h
include/linux/llist.h
include/linux/local_lock.h
include/linux/local_lock_internal.h
include/linux/lockdep.h
include/linux/lockdep_types.h
include/linux/lockref.h
include/linux/log2.h
include/linux/logic_pio.h
include/linux/math.h
include/linux/math64.h
include/linux/mdio.h
include/linux/mem_encrypt.h
include/linux/memblock.h
include/linux/memcontrol.h
include/linux/memory_hotplug.h
include/linux/mempolicy.h
include/linux/mempool.h
include/linux/memremap.h
include/linux/migrate.h
include/linux/migrate_mode.h
include/linux/mii.h
include/linux/mii_timestamper.h
include/linux/minmax.h
include/linux/mm.h
include/linux/mm_types.h
include/linux/mm_types_task.h
include/linux/mman.h
include/linux/mmap_lock.h
include/linux/mmdebug.h
include/linux/mmu_context.h
include/linux/mmu_notifier.h
include/linux/mmzone.h
include/linux/mod_devicetable.h
include/linux/module.h
include/linux/moduleparam.h
include/linux/mount.h
include/linux/msi.h
include/linux/mutex.h
include/linux/net.h
include/linux/netdev_features.h
include/linux/netdevice.h
include/linux/netfilter_defs.h
include/linux/netlink.h
include/linux/nfs_fs_i.h
include/linux/nls.h
include/linux/nmi.h
include/linux/node.h
include/linux/nodemask.h
include/linux/notifier.h
include/linux/ns_common.h
include/linux/nsproxy.h
include/linux/numa.h
include/linux/nvmem-provider.h
include/linux/objtool.h
include/linux/of.h
include/linux/of_address.h
include/linux/of_clk.h
include/linux/of_device.h
include/linux/of_fdt.h
include/linux/of_graph.h
include/linux/of_irq.h
include/linux/of_pci.h
include/linux/of_platform.h
include/linux/once.h
include/linux/once_lite.h
include/linux/osq_lock.h
include/linux/overflow.h
include/linux/page-flags-layout.h
include/linux/page-flags.h
include/linux/page_counter.h
include/linux/page_ext.h
include/linux/page_ref.h
include/linux/pageblock-flags.h
include/linux/pagemap.h
include/linux/panic.h
include/linux/panic_notifier.h
include/linux/path.h
include/linux/pci-dma-compat.h
include/linux/pci.h
include/linux/pci_hotplug.h
include/linux/pci_ids.h
include/linux/percpu-defs.h
include/linux/percpu-refcount.h
include/linux/percpu-rwsem.h
include/linux/percpu.h
include/linux/percpu_counter.h
include/linux/perf_event.h
include/linux/perf_regs.h
include/linux/personality.h
include/linux/pfn.h
include/linux/phy.h
include/linux/pid.h
include/linux/pid_namespace.h
include/linux/pinctrl/devinfo.h
include/linux/pipe_fs_i.h
include/linux/pkeys.h
include/linux/platform_device.h
include/linux/plist.h
include/linux/pm.h
include/linux/pm_domain.h
include/linux/pm_qos.h
include/linux/pm_runtime.h
include/linux/pm_wakeup.h
include/linux/poison.h
include/linux/poll.h
include/linux/posix-timers.h
include/linux/prandom.h
include/linux/preempt.h
include/linux/prefetch.h
include/linux/printk.h
include/linux/proc_fs.h
include/linux/processor.h
include/linux/profile.h
include/linux/projid.h
include/linux/property.h
include/linux/pseudo_fs.h
include/linux/psi.h
include/linux/psi_types.h
include/linux/ptr_ring.h
include/linux/ptrace.h
include/linux/pvclock_gtod.h
include/linux/quota.h
include/linux/radix-tree.h
include/linux/random.h
include/linux/range.h
include/linux/ratelimit.h
include/linux/ratelimit_types.h
include/linux/rbtree.h
include/linux/rbtree_augmented.h
include/linux/rbtree_latch.h
include/linux/rcu_segcblist.h
include/linux/rcu_sync.h
include/linux/rculist.h
include/linux/rculist_bl.h
include/linux/rculist_nulls.h
include/linux/rcupdate.h
include/linux/rcupdate_wait.h
include/linux/rcutiny.h
include/linux/rcuwait.h
include/linux/reboot.h
include/linux/refcount.h
include/linux/resource.h
include/linux/resource_ext.h
include/linux/restart_block.h
include/linux/rhashtable-types.h
include/linux/ring_buffer.h
include/linux/rtc.h
include/linux/rtnetlink.h
include/linux/rwlock.h
include/linux/rwlock_types.h
include/linux/rwsem.h
include/linux/sbitmap.h
include/linux/scatterlist.h
include/linux/sched.h
include/linux/sched/autogroup.h
include/linux/sched/clock.h
include/linux/sched/coredump.h
include/linux/sched/cpufreq.h
include/linux/sched/cputime.h
include/linux/sched/deadline.h
include/linux/sched/debug.h
include/linux/sched/hotplug.h
include/linux/sched/idle.h
include/linux/sched/init.h
include/linux/sched/isolation.h
include/linux/sched/jobctl.h
include/linux/sched/loadavg.h
include/linux/sched/mm.h
include/linux/sched/nohz.h
include/linux/sched/numa_balancing.h
include/linux/sched/prio.h
include/linux/sched/rt.h
include/linux/sched/signal.h
include/linux/sched/smt.h
include/linux/sched/stat.h
include/linux/sched/sysctl.h
include/linux/sched/task.h
include/linux/sched/task_stack.h
include/linux/sched/topology.h
include/linux/sched/types.h
include/linux/sched/user.h
include/linux/sched/wake_q.h
include/linux/sched/xacct.h
include/linux/sched_clock.h
include/linux/screen_info.h
include/linux/seccomp.h
include/linux/securebits.h
include/linux/security.h
include/linux/sem.h
include/linux/semaphore.h
include/linux/seq_buf.h
include/linux/seq_file.h
include/linux/seq_file_net.h
include/linux/seqlock.h
include/linux/set_memory.h
include/linux/shm.h
include/linux/shrinker.h
include/linux/signal.h
include/linux/signal_types.h
include/linux/siphash.h
include/linux/sizes.h
include/linux/skbuff.h
include/linux/slab.h
include/linux/smp.h
include/linux/smp_types.h
include/linux/smpboot.h
include/linux/socket.h
include/linux/sockptr.h
include/linux/sort.h
include/linux/spinlock.h
include/linux/spinlock_api_up.h
include/linux/spinlock_types.h
include/linux/spinlock_types_up.h
include/linux/spinlock_up.h
include/linux/splice.h
include/linux/srcu.h
include/linux/srcutiny.h
include/linux/stackdepot.h
include/linux/stacktrace.h
include/linux/stat.h
include/linux/static_call.h
include/linux/static_call_types.h
include/linux/static_key.h
include/linux/stddef.h
include/linux/stop_machine.h
include/linux/string.h
include/linux/string_helpers.h
include/linux/stringhash.h
include/linux/stringify.h
include/linux/suspend.h
include/linux/swab.h
include/linux/swait.h
include/linux/swap.h
include/linux/sync_core.h
include/linux/syscall_user_dispatch.h
include/linux/syscalls.h
include/linux/syscore_ops.h
include/linux/sysctl.h
include/linux/sysfs.h
include/linux/sysrq.h
include/linux/task_io_accounting.h
include/linux/task_work.h
include/linux/tcp.h
include/linux/textsearch.h
include/linux/thread_info.h
include/linux/threads.h
include/linux/tick.h
include/linux/time.h
include/linux/time32.h
include/linux/time64.h
include/linux/timecounter.h
include/linux/timekeeper_internal.h
include/linux/timekeeping.h
include/linux/timer.h
include/linux/timerqueue.h
include/linux/timex.h
include/linux/topology.h
include/linux/trace_clock.h
include/linux/trace_events.h
include/linux/trace_recursion.h
include/linux/trace_seq.h
include/linux/tracepoint-defs.h
include/linux/tracepoint.h
include/linux/tsacct_kern.h
include/linux/tty.h
include/linux/tty_driver.h
include/linux/tty_ldisc.h
include/linux/typecheck.h
include/linux/types.h
include/linux/u64_stats_sync.h
include/linux/uaccess.h
include/linux/udp.h
include/linux/uidgid.h
include/linux/uio.h
include/linux/umh.h
include/linux/unaligned/packed_struct.h
include/linux/uprobes.h
include/linux/user.h
include/linux/user_namespace.h
include/linux/userfaultfd_k.h
include/linux/utsname.h
include/linux/uuid.h
include/linux/vgaarb.h
include/linux/vm_event_item.h
include/linux/vmalloc.h
include/linux/vmpressure.h
include/linux/vmstat.h
include/linux/vt.h
include/linux/vt_kern.h
include/linux/vtime.h
include/linux/wait.h
include/linux/wait_bit.h
include/linux/win_minmax.h
include/linux/workqueue.h
include/linux/writeback.h
include/linux/ww_mutex.h
include/linux/xarray.h
include/net/addrconf.h
include/net/checksum.h
include/net/dst.h
include/net/dst_ops.h
include/net/fib_notifier.h
include/net/fib_rules.h
include/net/flow.h
include/net/flow_dissector.h
include/net/flow_offload.h
include/net/gen_stats.h
include/net/if_inet6.h
include/net/inet_connection_sock.h
include/net/inet_frag.h
include/net/inet_sock.h
include/net/inet_timewait_sock.h
include/net/ipv6.h
include/net/ipv6_stubs.h
include/net/l3mdev.h
include/net/ndisc.h
include/net/neighbour.h
include/net/net_namespace.h
include/net/netlink.h
include/net/netns/bpf.h
include/net/netns/can.h
include/net/netns/core.h
include/net/netns/hash.h
include/net/netns/ieee802154_6lowpan.h
include/net/netns/ipv4.h
include/net/netns/ipv6.h
include/net/netns/mib.h
include/net/netns/mpls.h
include/net/netns/netfilter.h
include/net/netns/nexthop.h
include/net/netns/nftables.h
include/net/netns/packet.h
include/net/netns/sctp.h
include/net/netns/smc.h
include/net/netns/unix.h
include/net/netns/x_tables.h
include/net/netns/xdp.h
include/net/netns/xfrm.h
include/net/netprio_cgroup.h
include/net/page_pool.h
include/net/request_sock.h
include/net/rtnetlink.h
include/net/sch_generic.h
include/net/scm.h
include/net/snmp.h
include/net/sock.h
include/net/tcp_states.h
include/net/timewait_sock.h
include/net/xdp.h
include/trace/define_trace.h
include/trace/events/irq.h
include/trace/events/power.h
include/trace/events/sched.h
include/trace/events/timer.h
include/trace/events/tlb.h
include/trace/events/workqueue.h
include/trace/syscall.h
include/uapi/asm-generic/bitsperlong.h
include/uapi/asm-generic/bpf_perf_event.h
include/uapi/asm-generic/errno-base.h
include/uapi/asm-generic/errno.h
include/uapi/asm-generic/fcntl.h
include/uapi/asm-generic/hugetlb_encode.h
include/uapi/asm-generic/int-ll64.h
include/uapi/asm-generic/ioctl.h
include/uapi/asm-generic/ioctls.h
include/uapi/asm-generic/ipcbuf.h
include/uapi/asm-generic/mman-common.h
include/uapi/asm-generic/mman.h
include/uapi/asm-generic/param.h
include/uapi/asm-generic/poll.h
include/uapi/asm-generic/posix_types.h
include/uapi/asm-generic/resource.h
include/uapi/asm-generic/shmbuf.h
include/uapi/asm-generic/siginfo.h
include/uapi/asm-generic/signal-defs.h
include/uapi/asm-generic/socket.h
include/uapi/asm-generic/sockios.h
include/uapi/asm-generic/termbits.h
include/uapi/asm-generic/termios.h
include/uapi/asm-generic/types.h
include/uapi/linux/aio_abi.h
include/uapi/linux/apm_bios.h
include/uapi/linux/audit.h
include/uapi/linux/auxvec.h
include/uapi/linux/binfmts.h
include/uapi/linux/blkzoned.h
include/uapi/linux/bpf.h
include/uapi/linux/bpf_common.h
include/uapi/linux/bpf_perf_event.h
include/uapi/linux/bsg.h
include/uapi/linux/byteorder/little_endian.h
include/uapi/linux/capability.h
include/uapi/linux/cgroupstats.h
include/uapi/linux/const.h
include/uapi/linux/dqblk_xfs.h
include/uapi/linux/edd.h
include/uapi/linux/elf-em.h
include/uapi/linux/elf.h
include/uapi/linux/errno.h
include/uapi/linux/ethtool.h
include/uapi/linux/eventpoll.h
include/uapi/linux/fcntl.h
include/uapi/linux/fib_rules.h
include/uapi/linux/filter.h
include/uapi/linux/fs.h
include/uapi/linux/gen_stats.h
include/uapi/linux/hdlc/ioctl.h
include/uapi/linux/icmpv6.h
include/uapi/linux/if.h
include/uapi/linux/if_addr.h
include/uapi/linux/if_arp.h
include/uapi/linux/if_bonding.h
include/uapi/linux/if_ether.h
include/uapi/linux/if_link.h
include/uapi/linux/if_packet.h
include/uapi/linux/if_vlan.h
include/uapi/linux/in.h
include/uapi/linux/in6.h
include/uapi/linux/ioctl.h
include/uapi/linux/ipc.h
include/uapi/linux/ipv6.h
include/uapi/linux/irqnr.h
include/uapi/linux/kd.h
include/uapi/linux/kdev_t.h
include/uapi/linux/kernel.h
include/uapi/linux/kexec.h
include/uapi/linux/kvm_para.h
include/uapi/linux/libc-compat.h
include/uapi/linux/limits.h
include/uapi/linux/magic.h
include/uapi/linux/major.h
include/uapi/linux/mdio.h
include/uapi/linux/membarrier.h
include/uapi/linux/mempolicy.h
include/uapi/linux/mii.h
include/uapi/linux/mman.h
include/uapi/linux/neighbour.h
include/uapi/linux/net.h
include/uapi/linux/net_tstamp.h
include/uapi/linux/netdevice.h
include/uapi/linux/netfilter.h
include/uapi/linux/netfilter/nf_tables.h
include/uapi/linux/netlink.h
include/uapi/linux/openat2.h
include/uapi/linux/param.h
include/uapi/linux/pci.h
include/uapi/linux/pci_regs.h
include/uapi/linux/perf_event.h
include/uapi/linux/personality.h
include/uapi/linux/pkt_cls.h
include/uapi/linux/pkt_sched.h
include/uapi/linux/poll.h
include/uapi/linux/posix_types.h
include/uapi/linux/ptrace.h
include/uapi/linux/quota.h
include/uapi/linux/random.h
include/uapi/linux/reboot.h
include/uapi/linux/resource.h
include/uapi/linux/rseq.h
include/uapi/linux/rtc.h
include/uapi/linux/rtnetlink.h
include/uapi/linux/sched.h
include/uapi/linux/sched/types.h
include/uapi/linux/screen_info.h
include/uapi/linux/seccomp.h
include/uapi/linux/securebits.h
include/uapi/linux/sem.h
include/uapi/linux/shm.h
include/uapi/linux/signal.h
include/uapi/linux/snmp.h
include/uapi/linux/socket.h
include/uapi/linux/sockios.h
include/uapi/linux/stat.h
include/uapi/linux/stddef.h
include/uapi/linux/string.h
include/uapi/linux/swab.h
include/uapi/linux/sysctl.h
include/uapi/linux/sysinfo.h
include/uapi/linux/taskstats.h
include/uapi/linux/tcp.h
include/uapi/linux/termios.h
include/uapi/linux/time.h
include/uapi/linux/time_types.h
include/uapi/linux/timex.h
include/uapi/linux/tty.h
include/uapi/linux/tty_flags.h
include/uapi/linux/types.h
include/uapi/linux/udp.h
include/uapi/linux/uio.h
include/uapi/linux/unistd.h
include/uapi/linux/utsname.h
include/uapi/linux/uuid.h
include/uapi/linux/vt.h
include/uapi/linux/wait.h
include/uapi/linux/xfrm.h
include/uapi/video/edid.h
include/vdso/bits.h
include/vdso/clocksource.h
include/vdso/const.h
include/vdso/jiffies.h
include/vdso/ktime.h
include/vdso/limits.h
include/vdso/math64.h
include/vdso/time.h
include/vdso/time32.h
include/vdso/time64.h
include/video/edid.h
include/video/vga.h
kernel/irq/debug.h
kernel/irq/internals.h
kernel/irq/settings.h
kernel/locking/lock_events.h
kernel/locking/lock_events_list.h
kernel/locking/mutex.h
kernel/sched/autogroup.h
kernel/sched/cpudeadline.h
kernel/sched/cpupri.h
kernel/sched/features.h
kernel/sched/sched.h
kernel/sched/stats.h
kernel/smpboot.h
kernel/time/ntp_internal.h
kernel/time/tick-internal.h
kernel/time/tick-sched.h
kernel/time/timekeeping.h
kernel/time/timekeeping_internal.h
kernel/workqueue_internal.h
lib/crc32defs.h
lib/kstrtox.h
mm/internal.h
mm/slab.h

View File

@ -0,0 +1,78 @@
/*
* \brief Supplement for emulation of kernel/dma/mapping.c
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* Copyright (C) 2022 Genode Labs GmbH
*
* This file is distributed under the terms of the GNU General Public License
* version 2.
*/
#include <lx_emul/alloc.h>
#include <linux/dma-mapping.h>
dma_addr_t dma_map_page_attrs(struct device * dev,
struct page * page,
size_t offset,
size_t size,
enum dma_data_direction dir,
unsigned long attrs)
{
dma_addr_t const dma_addr = page_to_phys(page);
unsigned long const virt_addr = (unsigned long)page_to_virt(page);
lx_emul_mem_cache_clean_invalidate((void *)(virt_addr + offset), size);
return dma_addr + offset;
}
void dma_unmap_page_attrs(struct device * dev,
dma_addr_t addr,
size_t size,
enum dma_data_direction dir,
unsigned long attrs)
{
unsigned long const virt_addr = lx_emul_mem_virt_addr((void*)addr);
if (!virt_addr)
return;
if (dir == DMA_FROM_DEVICE)
lx_emul_mem_cache_invalidate((void *)virt_addr, size);
}
void dma_sync_single_for_cpu(struct device *dev, dma_addr_t addr,
size_t size, enum dma_data_direction dir)
{
unsigned long const virt_addr = lx_emul_mem_virt_addr((void*)addr);
if (!virt_addr)
return;
lx_emul_mem_cache_invalidate((void *)virt_addr, size);
}
void dma_sync_single_for_device(struct device *dev, dma_addr_t addr,
size_t size, enum dma_data_direction dir)
{
unsigned long const virt_addr = lx_emul_mem_virt_addr((void*)addr);
if (!virt_addr)
return;
lx_emul_mem_cache_clean_invalidate((void *)virt_addr, size);
}
int dma_supported(struct device * dev,u64 mask)
{
lx_emul_trace(__func__);
return 1;
}

View File

@ -0,0 +1,34 @@
/*
* \brief Supplement for emulation of mm/page_alloc.c
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* Copyright (C) 2022 Genode Labs GmbH
*
* This file is distributed under the terms of the GNU General Public License
* version 2.
*/
#include <linux/gfp.h>
#include <linux/mm.h>
void free_pages(unsigned long addr,unsigned int order)
{
if (addr != 0ul)
__free_pages(virt_to_page((void *)addr), order);
}
unsigned long __get_free_pages(gfp_t gfp_mask, unsigned int order)
{
struct page *page = alloc_pages(gfp_mask & ~__GFP_HIGHMEM, order);
if (!page)
return 0;
return (unsigned long)page_address(page);
}

View File

@ -0,0 +1,23 @@
/*
* \brief Supplement for emulation of kernel/sched/core.c
* \author Josef Soentgen
* \date 2022-05-05
*/
/*
* 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 <linux/sched.h>
void sched_set_fifo(struct task_struct * p)
{
lx_emul_trace(__func__);
}

View File

@ -0,0 +1,24 @@
/*
* \brief Replaces drivers/acpi/bus.c
* \author Josef Soentgen
* \date 2022-05-06
*/
/*
* 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 <linux/acpi.h>
struct device_driver;
bool acpi_driver_match_device(struct device *dev, const struct device_driver *drv)
{
lx_emul_trace(__func__);
return false;
}

View File

@ -0,0 +1,30 @@
/*
* \brief Replaces drivers/acpi/device_sysfs.c
* \author Josef Soentgen
* \date 2022-05-06
*/
/*
* 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 <linux/acpi.h>
int acpi_device_uevent_modalias(struct device *dev, struct kobj_uevent_env *event)
{
lx_emul_trace(__func__);
return -1;
}
int acpi_device_modalias(struct device *device, char * x, int y)
{
lx_emul_trace(__func__);
return -1;
}

View File

@ -0,0 +1,23 @@
/*
* \brief Replaces drivers/acpi/glue.c
* \author Josef Soentgen
* \date 2022-05-05
*/
/*
* 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 <linux/kobject.h>
#include <linux/acpi.h>
int acpi_platform_notify(struct device *dev, enum kobject_action action)
{
lx_emul_trace(__func__);
return 0;
}

View File

@ -0,0 +1,23 @@
/*
* \brief Replaces drivers/acpi/property.c
* \author Josef Soentgen
* \date 2022-05-06
*/
/*
* 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 <linux/acpi.h>
bool is_acpi_device_node(const struct fwnode_handle *fwnode)
{
lx_emul_trace(__func__);
return false;
}

View File

@ -0,0 +1,30 @@
/*
* \brief Replaces drivers/acpi/scan.c
* \author Josef Soentgen
* \date 2022-05-06
*/
/*
* 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 <linux/acpi.h>
enum dev_dma_attr acpi_get_dma_attr(struct acpi_device *adev)
{
lx_emul_trace(__func__);
return DEV_DMA_NOT_SUPPORTED;
}
int acpi_dma_configure_id(struct device *dev, enum dev_dma_attr attr, const u32 *input_id)
{
lx_emul_trace(__func__);
return -1;
}

View File

@ -0,0 +1,31 @@
/*
* \brief Replaces drivers/acpi/utils.c
* \author Josef Soentgen
* \date 2022-05-06
*/
/*
* 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 <linux/acpi.h>
bool acpi_check_dsm(acpi_handle handle, const guid_t *guid, u64 rev, u64 funcs)
{
lx_emul_trace(__func__);
return false;
}
union acpi_object *acpi_evaluate_dsm(acpi_handle handle, const guid_t *guid,
u64 rev, u64 func, union acpi_object *argv4)
{
lx_emul_trace(__func__);
return NULL;
}

View File

@ -0,0 +1,28 @@
/*
* \brief Replaces drivers/char/random.c
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* 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 <linux/random.h>
void get_random_bytes(void * buf,int nbytes)
{
lx_emul_trace(__func__);
}
int __must_check get_random_bytes_arch(void * buf,int nbytes)
{
lx_emul_trace(__func__);
return 0;
}

View File

@ -0,0 +1,47 @@
/*
* \brief Dummy definitions of Linux Kernel functions
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* 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 <linux/fs.h>
#include <linux/mount.h>
#include <linux/slab.h>
int simple_pin_fs(struct file_system_type * type, struct vfsmount ** mount, int * count)
{
if (!mount)
return -EFAULT;
if (!*mount)
*mount = kzalloc(sizeof(struct vfsmount), GFP_KERNEL);
if (!*mount)
return -ENOMEM;
if (count)
++*count;
return 0;
}
void simple_release_fs(struct vfsmount ** mount,int * count)
{
kfree(*mount);
}
struct inode * alloc_anon_inode(struct super_block * s)
{
return kzalloc(sizeof(struct inode), GFP_KERNEL);
}

View File

@ -0,0 +1,37 @@
/*
* \brief Replaces fs/sysfs/dir.c
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* 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 <linux/slab.h>
#include <linux/kobject.h>
#include <linux/sysfs.h>
int sysfs_create_dir_ns(struct kobject * kobj,const void * ns)
{
if (!kobj)
return -EINVAL;
kobj->sd = kzalloc(sizeof(*kobj->sd), GFP_KERNEL);
return 0;
}
void sysfs_remove_dir(struct kobject * kobj)
{
if (!kobj)
return;
kfree(kobj->sd);
}

View File

@ -0,0 +1,81 @@
/*
* \brief Replaces fs/sysfs/file.c
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* 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 <linux/sysfs.h>
int sysfs_create_bin_file(struct kobject * kobj,const struct bin_attribute * attr)
{
lx_emul_trace(__func__);
return 0;
}
void sysfs_remove_bin_file(struct kobject * kobj,const struct bin_attribute * attr)
{
lx_emul_trace(__func__);
}
int sysfs_create_file_ns(struct kobject * kobj,const struct attribute * attr,const void * ns)
{
lx_emul_trace(__func__);
return 0;
}
void sysfs_remove_file_ns(struct kobject * kobj,const struct attribute * attr,const void * ns)
{
lx_emul_trace(__func__);
}
int sysfs_create_files(struct kobject * kobj,const struct attribute * const * ptr)
{
lx_emul_trace(__func__);
return 0;
}
void sysfs_remove_files(struct kobject * kobj,const struct attribute * const * ptr)
{
lx_emul_trace(__func__);
}
bool sysfs_remove_file_self(struct kobject * kobj,const struct attribute * attr)
{
lx_emul_trace(__func__);
return false;
}
int sysfs_emit(char * buf,const char * fmt,...)
{
lx_emul_trace(__func__);
return PAGE_SIZE;
}
int sysfs_emit_at(char * buf, int at, const char * fmt,...)
{
lx_emul_trace(__func__);
return at > PAGE_SIZE ? PAGE_SIZE : PAGE_SIZE - at;
}
void sysfs_notify(struct kobject * kobj,const char * dir,const char * attr)
{
lx_emul_trace(__func__);
}

View File

@ -0,0 +1,41 @@
/*
* \brief Replaces fs/sysfs/group.c
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* 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 <linux/sysfs.h>
int sysfs_create_groups(struct kobject * kobj,const struct attribute_group ** groups)
{
lx_emul_trace(__func__);
return 0;
}
int sysfs_create_group(struct kobject * kobj,const struct attribute_group * grp)
{
lx_emul_trace(__func__);
return 0;
}
void sysfs_remove_group(struct kobject * kobj,const struct attribute_group * grp)
{
lx_emul_trace(__func__);
}
void sysfs_remove_groups(struct kobject * kobj,const struct attribute_group ** groups)
{
lx_emul_trace(__func__);
}

View File

@ -0,0 +1,34 @@
/*
* \brief Replaces fs/sysfs/symlink.c
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* 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 <linux/sysfs.h>
int sysfs_create_link(struct kobject * kobj,struct kobject * target,const char * name)
{
lx_emul_trace(__func__);
return 0;
}
void sysfs_delete_link(struct kobject * kobj,struct kobject * targ,const char * name)
{
lx_emul_trace(__func__);
}
void sysfs_remove_link(struct kobject * kobj,const char * name)
{
lx_emul_trace(__func__);
}

View File

@ -0,0 +1,30 @@
/*
* \brief Replaces kernel/rcu/tiny.c
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* Copyright (C) 2022 Genode Labs GmbH
*
* This file is distributed under the terms of the GNU General Public License
* version 2.
*/
#include <linux/rcupdate.h>
void call_rcu(struct rcu_head * head,rcu_callback_t func)
{
/*
* In case func is a small offset kvfree should be
* called directly, see 'rcu_reclaim_tiny'.
*/
enum { KVFREE_RCU_OFFSET = 4096, };
if (func < (rcu_callback_t)KVFREE_RCU_OFFSET) {
kvfree((void*)head - (unsigned long)func);
return;
}
func(head);
}

View File

@ -0,0 +1,20 @@
/*
* \brief Replaces lib/kobject_uevent.c
* \author Josef Soentgen
* \date 2022-05-03
*/
/*
* Copyright (C) 2022 Genode Labs GmbH
*
* This file is distributed under the terms of the GNU General Public License
* version 2.
*/
#include <linux/kobject.h>
int kobject_uevent(struct kobject * kobj,enum kobject_action action)
{
return 0;
}

View File

@ -0,0 +1,29 @@
/*
* \brief Replaces lib/logic_iomem.c
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* Copyright (C) 2022 Genode Labs GmbH
*
* This file is distributed under the terms of the GNU General Public License
* version 2.
*/
#include <lx_emul/io_mem.h>
#include <asm-generic/logic_io.h>
void __iomem * ioremap(resource_size_t phys_addr, unsigned long size)
{
return lx_emul_io_mem_map(phys_addr, size);
}
void iounmap(volatile void __iomem * addr)
{
(void)addr;
}

View File

@ -0,0 +1,77 @@
/*
* \brief Replaces mm/dmapool.c
* \author josef soentgen
* \date 2022-04-05
*/
/*
* Copyright (C) 2022 Genode Labs GmbH
*
* This file is distributed under the terms of the GNU General Public License
* version 2.
*/
#include <linux/slab.h>
#include <linux/dmapool.h>
struct dma_pool
{
size_t size;
size_t align;
};
void * dma_pool_alloc(struct dma_pool * pool, gfp_t mem_flags, dma_addr_t * handle)
{
void * ret =
lx_emul_mem_alloc_aligned_uncached(pool->size, pool->align);
*handle = lx_emul_mem_dma_addr(ret);
return ret;
}
struct dma_pool * dma_pool_create(const char * name,
struct device * dev,
size_t size,
size_t align,
size_t boundary)
{
struct dma_pool * pool = kzalloc(sizeof(struct dma_pool), GFP_KERNEL);
if (!pool)
return NULL;
/* TODO check if it makes sense to add min(align, PAGE_SIZE) check */
pool->size = size;
pool->align = align;
return pool;
}
struct dma_pool *dmam_pool_create(const char *name,
struct device *dev,
size_t size,
size_t align,
size_t allocation)
{
/*
* Only take care of allocating the pool because
* we do not detach the driver anyway.
*/
return dma_pool_create(name, dev, size, align, 0);
}
void dma_pool_destroy(struct dma_pool * pool)
{
kfree(pool);
}
void dma_pool_free(struct dma_pool * pool,void * vaddr,dma_addr_t dma)
{
lx_emul_mem_free(vaddr);
}

View File

@ -0,0 +1,22 @@
/*
* \brief Supplement for emulation of mm/slab_common.c
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* Copyright (C) 2022 Genode Labs GmbH
*
* This file is distributed under the terms of the GNU General Public License
* version 2.
*/
#include <linux/slab.h>
void * kmalloc_order(size_t size, gfp_t flags, unsigned int order)
{
return kmalloc(size, flags);
}

View File

@ -0,0 +1,40 @@
/*
* \brief Supplement for emulation of kernel/softirq.c
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* Copyright (C) 2022 Genode Labs GmbH
*
* This file is distributed under the terms of the GNU General Public License
* version 2.
*/
#include <linux/interrupt.h>
void tasklet_setup(struct tasklet_struct * t,
void (* callback)(struct tasklet_struct *))
{
t->next = NULL;
t->state = 0;
atomic_set(&t->count, 0);
t->callback = callback;
t->use_callback = true;
t->data = 0;
}
void __tasklet_schedule(struct tasklet_struct * t)
{
if (test_and_clear_bit(TASKLET_STATE_SCHED, &t->state))
t->callback(t);
}
void __tasklet_hi_schedule(struct tasklet_struct * t)
{
if (test_and_clear_bit(TASKLET_STATE_SCHED, &t->state))
t->callback(t);
}

View File

@ -0,0 +1,39 @@
/*
* \brief Supplement for emulation of mm/vmalloc.c
* \author Josef Soentgen
* \date 2022-04-05
*/
/*
* Copyright (C) 2022 Genode Labs GmbH
*
* This file is distributed under the terms of the GNU General Public License
* version 2.
*/
#include <linux/slab.h>
#include <linux/vmalloc.h>
void vfree(const void * addr)
{
kfree(addr);
}
void * vmalloc(unsigned long size)
{
return kmalloc(size, GFP_KERNEL);
}
void * vzalloc(unsigned long size)
{
return kzalloc(size, GFP_KERNEL);
}
bool is_vmalloc_addr(const void * x)
{
return false;
}

View File

@ -0,0 +1,319 @@
arch/x86/include/asm/vdso/processor.h
certs/common.h
crypto/internal.h
drivers/net/wireless/intel/iwlwifi/dvm/agn.h
drivers/net/wireless/intel/iwlwifi/dvm/calib.h
drivers/net/wireless/intel/iwlwifi/dvm/commands.h
drivers/net/wireless/intel/iwlwifi/dvm/dev.h
drivers/net/wireless/intel/iwlwifi/dvm/led.h
drivers/net/wireless/intel/iwlwifi/dvm/power.h
drivers/net/wireless/intel/iwlwifi/dvm/rs.h
drivers/net/wireless/intel/iwlwifi/dvm/tt.h
drivers/net/wireless/intel/iwlwifi/fw/acpi.h
drivers/net/wireless/intel/iwlwifi/fw/api/alive.h
drivers/net/wireless/intel/iwlwifi/fw/api/binding.h
drivers/net/wireless/intel/iwlwifi/fw/api/cmdhdr.h
drivers/net/wireless/intel/iwlwifi/fw/api/coex.h
drivers/net/wireless/intel/iwlwifi/fw/api/commands.h
drivers/net/wireless/intel/iwlwifi/fw/api/config.h
drivers/net/wireless/intel/iwlwifi/fw/api/context.h
drivers/net/wireless/intel/iwlwifi/fw/api/d3.h
drivers/net/wireless/intel/iwlwifi/fw/api/datapath.h
drivers/net/wireless/intel/iwlwifi/fw/api/dbg-tlv.h
drivers/net/wireless/intel/iwlwifi/fw/api/debug.h
drivers/net/wireless/intel/iwlwifi/fw/api/filter.h
drivers/net/wireless/intel/iwlwifi/fw/api/led.h
drivers/net/wireless/intel/iwlwifi/fw/api/location.h
drivers/net/wireless/intel/iwlwifi/fw/api/mac-cfg.h
drivers/net/wireless/intel/iwlwifi/fw/api/mac.h
drivers/net/wireless/intel/iwlwifi/fw/api/nvm-reg.h
drivers/net/wireless/intel/iwlwifi/fw/api/offload.h
drivers/net/wireless/intel/iwlwifi/fw/api/paging.h
drivers/net/wireless/intel/iwlwifi/fw/api/phy-ctxt.h
drivers/net/wireless/intel/iwlwifi/fw/api/phy.h
drivers/net/wireless/intel/iwlwifi/fw/api/power.h
drivers/net/wireless/intel/iwlwifi/fw/api/rfi.h
drivers/net/wireless/intel/iwlwifi/fw/api/rs.h
drivers/net/wireless/intel/iwlwifi/fw/api/rx.h
drivers/net/wireless/intel/iwlwifi/fw/api/scan.h
drivers/net/wireless/intel/iwlwifi/fw/api/sf.h
drivers/net/wireless/intel/iwlwifi/fw/api/soc.h
drivers/net/wireless/intel/iwlwifi/fw/api/sta.h
drivers/net/wireless/intel/iwlwifi/fw/api/stats.h
drivers/net/wireless/intel/iwlwifi/fw/api/tdls.h
drivers/net/wireless/intel/iwlwifi/fw/api/time-event.h
drivers/net/wireless/intel/iwlwifi/fw/api/tx.h
drivers/net/wireless/intel/iwlwifi/fw/api/txq.h
drivers/net/wireless/intel/iwlwifi/fw/dbg.h
drivers/net/wireless/intel/iwlwifi/fw/debugfs.h
drivers/net/wireless/intel/iwlwifi/fw/error-dump.h
drivers/net/wireless/intel/iwlwifi/fw/file.h
drivers/net/wireless/intel/iwlwifi/fw/img.h
drivers/net/wireless/intel/iwlwifi/fw/notif-wait.h
drivers/net/wireless/intel/iwlwifi/fw/pnvm.h
drivers/net/wireless/intel/iwlwifi/fw/runtime.h
drivers/net/wireless/intel/iwlwifi/fw/uefi.h
drivers/net/wireless/intel/iwlwifi/iwl-agn-hw.h
drivers/net/wireless/intel/iwlwifi/iwl-config.h
drivers/net/wireless/intel/iwlwifi/iwl-context-info-gen3.h
drivers/net/wireless/intel/iwlwifi/iwl-context-info.h
drivers/net/wireless/intel/iwlwifi/iwl-csr.h
drivers/net/wireless/intel/iwlwifi/iwl-dbg-tlv.h
drivers/net/wireless/intel/iwlwifi/iwl-debug.h
drivers/net/wireless/intel/iwlwifi/iwl-devtrace-data.h
drivers/net/wireless/intel/iwlwifi/iwl-devtrace-io.h
drivers/net/wireless/intel/iwlwifi/iwl-devtrace-iwlwifi.h
drivers/net/wireless/intel/iwlwifi/iwl-devtrace-msg.h
drivers/net/wireless/intel/iwlwifi/iwl-devtrace-ucode.h
drivers/net/wireless/intel/iwlwifi/iwl-devtrace.h
drivers/net/wireless/intel/iwlwifi/iwl-drv.h
drivers/net/wireless/intel/iwlwifi/iwl-eeprom-parse.h
drivers/net/wireless/intel/iwlwifi/iwl-eeprom-read.h
drivers/net/wireless/intel/iwlwifi/iwl-fh.h
drivers/net/wireless/intel/iwlwifi/iwl-io.h
drivers/net/wireless/intel/iwlwifi/iwl-modparams.h
drivers/net/wireless/intel/iwlwifi/iwl-nvm-parse.h
drivers/net/wireless/intel/iwlwifi/iwl-op-mode.h
drivers/net/wireless/intel/iwlwifi/iwl-phy-db.h
drivers/net/wireless/intel/iwlwifi/iwl-prph.h
drivers/net/wireless/intel/iwlwifi/iwl-scd.h
drivers/net/wireless/intel/iwlwifi/iwl-trans.h
drivers/net/wireless/intel/iwlwifi/mvm/constants.h
drivers/net/wireless/intel/iwlwifi/mvm/debugfs.h
drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h
drivers/net/wireless/intel/iwlwifi/mvm/mvm.h
drivers/net/wireless/intel/iwlwifi/mvm/rs.h
drivers/net/wireless/intel/iwlwifi/mvm/sta.h
drivers/net/wireless/intel/iwlwifi/mvm/testmode.h
drivers/net/wireless/intel/iwlwifi/mvm/time-event.h
drivers/net/wireless/intel/iwlwifi/pcie/internal.h
drivers/net/wireless/intel/iwlwifi/queue/tx.h
include/crypto/acompress.h
include/crypto/aead.h
include/crypto/aes.h
include/crypto/akcipher.h
include/crypto/algapi.h
include/crypto/arc4.h
include/crypto/b128ops.h
include/crypto/ctr.h
include/crypto/drbg.h
include/crypto/gcm.h
include/crypto/gf128mul.h
include/crypto/ghash.h
include/crypto/hash.h
include/crypto/hash_info.h
include/crypto/internal/acompress.h
include/crypto/internal/aead.h
include/crypto/internal/akcipher.h
include/crypto/internal/cipher.h
include/crypto/internal/geniv.h
include/crypto/internal/hash.h
include/crypto/internal/kpp.h
include/crypto/internal/rng.h
include/crypto/internal/scompress.h
include/crypto/internal/simd.h
include/crypto/internal/skcipher.h
include/crypto/kpp.h
include/crypto/md5.h
include/crypto/null.h
include/crypto/rng.h
include/crypto/scatterwalk.h
include/crypto/sha2.h
include/crypto/sha256_base.h
include/crypto/skcipher.h
include/crypto/streebog.h
include/dt-bindings/leds/common.h
include/linux/asn1.h
include/linux/asn1_ber_bytecode.h
include/linux/asn1_decoder.h
include/linux/average.h
include/linux/bpf_local_storage.h
include/linux/bpf_trace.h
include/linux/bsearch.h
include/linux/btf_ids.h
include/linux/cookie.h
include/linux/cpu_rmap.h
include/linux/crash_dump.h
include/linux/crypto.h
include/linux/devcoredump.h
include/linux/dmaengine.h
include/linux/errqueue.h
include/linux/ethtool_netlink.h
include/linux/fips.h
include/linux/firmware.h
include/linux/gcd.h
include/linux/genetlink.h
include/linux/ieee80211.h
include/linux/if_bridge.h
include/linux/if_macvlan.h
include/linux/if_tun.h
include/linux/if_tunnel.h
include/linux/inet.h
include/linux/inetdevice.h
include/linux/ip.h
include/linux/ipv6_route.h
include/linux/kcov.h
include/linux/leds.h
include/linux/mpls.h
include/linux/netfilter.h
include/linux/netfilter_ingress.h
include/linux/netpoll.h
include/linux/nospec.h
include/linux/nvmem-consumer.h
include/linux/of_net.h
include/linux/phylink.h
include/linux/platform_data/dsa.h
include/linux/pps_kernel.h
include/linux/proc_ns.h
include/linux/ptp_classify.h
include/linux/ptp_clock_kernel.h
include/linux/rfkill.h
include/linux/rhashtable.h
include/linux/sctp.h
include/linux/skb_array.h
include/linux/sock_diag.h
include/linux/thermal.h
include/linux/trace.h
include/linux/units.h
include/linux/verification.h
include/linux/virtio.h
include/linux/virtio_byteorder.h
include/linux/virtio_config.h
include/linux/virtio_net.h
include/linux/wireless.h
include/linux/xattr.h
include/net/Space.h
include/net/act_api.h
include/net/arp.h
include/net/bpf_sk_storage.h
include/net/busy_poll.h
include/net/cfg80211-wext.h
include/net/cfg80211.h
include/net/cls_cgroup.h
include/net/codel.h
include/net/codel_impl.h
include/net/compat.h
include/net/devlink.h
include/net/dsa.h
include/net/dsfield.h
include/net/dst_cache.h
include/net/dst_metadata.h
include/net/fq.h
include/net/fq_impl.h
include/net/genetlink.h
include/net/gro.h
include/net/gro_cells.h
include/net/ieee80211_radiotap.h
include/net/inet_ecn.h
include/net/inet_hashtables.h
include/net/inetpeer.h
include/net/ip.h
include/net/ip6_checksum.h
include/net/ip6_fib.h
include/net/ip_fib.h
include/net/ip_tunnels.h
include/net/iw_handler.h
include/net/lwtunnel.h
include/net/mac80211.h
include/net/mpls.h
include/net/mptcp.h
include/net/netns/generic.h
include/net/pkt_cls.h
include/net/pkt_sched.h
include/net/protocol.h
include/net/regulatory.h
include/net/route.h
include/net/sock_reuseport.h
include/net/switchdev.h
include/net/tcp.h
include/net/tso.h
include/net/udp.h
include/net/udp_tunnel.h
include/net/wext.h
include/net/xdp_priv.h
include/net/xdp_sock.h
include/net/xdp_sock_drv.h
include/net/xfrm.h
include/net/xsk_buff_pool.h
include/trace/events/napi.h
include/trace/events/net.h
include/trace/events/netlink.h
include/trace/events/qdisc.h
include/trace/events/skb.h
include/trace/events/sock.h
include/trace/events/xdp.h
include/uapi/linux/btf.h
include/uapi/linux/cryptouser.h
include/uapi/linux/devlink.h
include/uapi/linux/errqueue.h
include/uapi/linux/ethtool_netlink.h
include/uapi/linux/genetlink.h
include/uapi/linux/hash_info.h
include/uapi/linux/if_bridge.h
include/uapi/linux/if_tun.h
include/uapi/linux/if_tunnel.h
include/uapi/linux/if_xdp.h
include/uapi/linux/in_route.h
include/uapi/linux/ip.h
include/uapi/linux/ipsec.h
include/uapi/linux/ipv6_route.h
include/uapi/linux/kcov.h
include/uapi/linux/lwtunnel.h
include/uapi/linux/mpls.h
include/uapi/linux/net_namespace.h
include/uapi/linux/nl80211.h
include/uapi/linux/pfkeyv2.h
include/uapi/linux/pps.h
include/uapi/linux/ptp_clock.h
include/uapi/linux/rfkill.h
include/uapi/linux/route.h
include/uapi/linux/sctp.h
include/uapi/linux/sock_diag.h
include/uapi/linux/thermal.h
include/uapi/linux/un.h
include/uapi/linux/virtio_config.h
include/uapi/linux/virtio_ids.h
include/uapi/linux/virtio_net.h
include/uapi/linux/virtio_types.h
include/uapi/linux/vmcore.h
include/uapi/linux/wireless.h
include/uapi/linux/xattr.h
net/core/datagram.h
net/core/net-sysfs.h
net/ethtool/common.h
net/mac80211/aead_api.h
net/mac80211/aes_ccm.h
net/mac80211/aes_cmac.h
net/mac80211/aes_gcm.h
net/mac80211/aes_gmac.h
net/mac80211/debug.h
net/mac80211/debugfs.h
net/mac80211/debugfs_key.h
net/mac80211/debugfs_netdev.h
net/mac80211/debugfs_sta.h
net/mac80211/driver-ops.h
net/mac80211/fils_aead.h
net/mac80211/ieee80211_i.h
net/mac80211/key.h
net/mac80211/led.h
net/mac80211/mesh.h
net/mac80211/michael.h
net/mac80211/rate.h
net/mac80211/rc80211_minstrel_ht.h
net/mac80211/sta_info.h
net/mac80211/tkip.h
net/mac80211/trace.h
net/mac80211/trace_msg.h
net/mac80211/wep.h
net/mac80211/wme.h
net/mac80211/wpa.h
net/netlink/af_netlink.h
net/packet/internal.h
net/wireless/core.h
net/wireless/debugfs.h
net/wireless/nl80211.h
net/wireless/rdev-ops.h
net/wireless/reg.h
net/wireless/sysfs.h
net/wireless/trace.h
net/wireless/wext-compat.h

View File

@ -13,269 +13,6 @@
#include <lx_emul.h> #include <lx_emul.h>
#include <linux/cpuhotplug.h>
int __cpuhp_setup_state(enum cpuhp_state state,const char * name,bool invoke,int (* startup)(unsigned int cpu),int (* teardown)(unsigned int cpu),bool multi_instance)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/timekeeper_internal.h>
void update_vsyscall(struct timekeeper * tk)
{
lx_emul_trace(__func__);
}
#include <linux/clocksource.h>
void clocksource_arch_init(struct clocksource * cs)
{
lx_emul_trace(__func__);
}
#include <linux/sched/signal.h>
void ignore_signals(struct task_struct * t)
{
lx_emul_trace(__func__);
}
#include <linux/sched/loadavg.h>
void calc_global_load(void)
{
lx_emul_trace(__func__);
}
#include <linux/kernel_stat.h>
void account_process_tick(struct task_struct * p,int user_tick)
{
lx_emul_trace(__func__);
}
#include <linux/rcupdate.h>
void rcu_sched_clock_irq(int user)
{
lx_emul_trace(__func__);
}
#include <linux/sysfs.h>
int sysfs_create_bin_file(struct kobject * kobj,const struct bin_attribute * attr)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/sysfs.h>
int sysfs_create_file_ns(struct kobject * kobj,const struct attribute * attr,const void * ns)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/sysfs.h>
int sysfs_create_groups(struct kobject * kobj,const struct attribute_group ** groups)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/sysfs.h>
int sysfs_create_group(struct kobject * kobj,const struct attribute_group * grp)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/sysfs.h>
int sysfs_create_link(struct kobject * kobj,struct kobject * target,const char * name)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/sysfs.h>
void sysfs_remove_link(struct kobject * kobj,const char * name)
{
lx_emul_trace(__func__);
}
#include <linux/sysfs.h>
void sysfs_remove_file_ns(struct kobject * kobj,const struct attribute * attr,const void * ns)
{
lx_emul_trace(__func__);
}
#include <linux/sysfs.h>
void sysfs_remove_groups(struct kobject * kobj,const struct attribute_group ** groups)
{
lx_emul_trace(__func__);
}
#include <linux/sysfs.h>
void sysfs_remove_dir(struct kobject * kobj)
{
lx_emul_trace(__func__);
}
#include <linux/sysfs.h>
void sysfs_remove_bin_file(struct kobject * kobj,const struct bin_attribute * attr)
{
lx_emul_trace(__func__);
}
#include <linux/kernfs.h>
void kernfs_get(struct kernfs_node * kn)
{
lx_emul_trace(__func__);
}
#include <linux/kernfs.h>
void kernfs_put(struct kernfs_node * kn)
{
lx_emul_trace(__func__);
}
#include <linux/kobject.h>
int kobject_uevent(struct kobject * kobj,enum kobject_action action)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/random.h>
int add_random_ready_callback(struct random_ready_callback * rdy)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/random.h>
void add_device_randomness(const void * buf,unsigned int size)
{
lx_emul_trace(__func__);
}
#include <linux/random.h>
void add_interrupt_randomness(int irq,int irq_flags)
{
lx_emul_trace(__func__);
}
extern bool irq_wait_for_poll(struct irq_desc * desc);
bool irq_wait_for_poll(struct irq_desc * desc)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/irq.h>
void note_interrupt(struct irq_desc * desc,irqreturn_t action_ret)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/fs.h>
int __register_chrdev(unsigned int major,unsigned int baseminor,unsigned int count,const char * name,const struct file_operations * fops)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/fs.h>
int register_chrdev_region(dev_t from,unsigned count,const char * name)
{
lx_emul_trace(__func__);
return 0;
}
extern void register_handler_proc(unsigned int irq,struct irqaction * action);
void register_handler_proc(unsigned int irq,struct irqaction * action)
{
lx_emul_trace(__func__);
}
extern void register_irq_proc(unsigned int irq,struct irq_desc * desc);
void register_irq_proc(unsigned int irq,struct irq_desc * desc)
{
lx_emul_trace(__func__);
}
#include <linux/cdev.h>
void cdev_init(struct cdev * cdev,const struct file_operations * fops)
{
lx_emul_trace(__func__);
}
#include <linux/cdev.h>
int cdev_add(struct cdev * p,dev_t dev,unsigned count)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/cdev.h>
void cdev_del(struct cdev * p)
{
lx_emul_trace(__func__);
}
#include <linux/syscore_ops.h> #include <linux/syscore_ops.h>
@ -285,159 +22,6 @@ void register_syscore_ops(struct syscore_ops * ops)
} }
#include <linux/proc_fs.h>
struct proc_dir_entry { int dummy; };
struct proc_dir_entry * proc_create_seq_private(const char * name,umode_t mode,struct proc_dir_entry * parent,const struct seq_operations * ops,unsigned int state_size,void * data)
{
static struct proc_dir_entry ret;
lx_emul_trace(__func__);
return &ret;
}
#include <linux/property.h>
int software_node_notify(struct device * dev,unsigned long action)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/utsname.h>
#include <linux/user_namespace.h>
struct user_namespace init_user_ns;
struct uts_namespace init_uts_ns;
/*
* linux/seq_file.h depends on user_namespace being defined, add
* all dummies pulling in this header below here
*/
#include <linux/seq_file.h>
void seq_vprintf(struct seq_file * m,const char * f,va_list args)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/vt_kern.h>
void unblank_screen(void)
{
lx_emul_trace_and_stop(__func__);
}
extern void pci_allocate_vc_save_buffers(struct pci_dev * dev);
void pci_allocate_vc_save_buffers(struct pci_dev * dev)
{
lx_emul_trace(__func__);
}
extern void pci_vpd_init(struct pci_dev * dev);
void pci_vpd_init(struct pci_dev * dev)
{
lx_emul_trace(__func__);
}
extern int pci_proc_attach_device(struct pci_dev * dev);
int pci_proc_attach_device(struct pci_dev * dev)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/kernel.h>
bool parse_option_str(const char * str,const char * option)
{
lx_emul_trace(__func__);
return false;
}
extern bool pat_enabled(void);
bool pat_enabled(void)
{
// XXX pat_enabled necessary?
lx_emul_trace(__func__);
return false;
}
#include <linux/mm.h>
bool is_vmalloc_addr(const void * x)
{
lx_emul_trace(__func__);
return false;
}
unsigned long init_stack[THREAD_SIZE / sizeof(unsigned long)];
extern int pci_dev_specific_acs_enabled(struct pci_dev * dev,u16 acs_flags);
int pci_dev_specific_acs_enabled(struct pci_dev * dev,u16 acs_flags)
{
lx_emul_trace(__func__);
return 0;
}
extern int pci_dev_specific_disable_acs_redir(struct pci_dev * dev);
int pci_dev_specific_disable_acs_redir(struct pci_dev * dev)
{
lx_emul_trace(__func__);
return 0;
}
extern int pci_dev_specific_enable_acs(struct pci_dev * dev);
int pci_dev_specific_enable_acs(struct pci_dev * dev)
{
lx_emul_trace(__func__);
return 0;
}
extern int pci_dev_specific_reset(struct pci_dev * dev,int probe);
int pci_dev_specific_reset(struct pci_dev * dev,int probe)
{
lx_emul_trace(__func__);
return 0;
}
#include <linux/pci.h>
void pci_fixup_device(enum pci_fixup_pass pass,struct pci_dev * dev)
{
lx_emul_trace(__func__);
}
#include <linux/pci.h>
int pci_disable_link_state(struct pci_dev * pdev,int state)
{
lx_emul_trace(__func__);
return 0;
}
const unsigned long module_cert_size = 0; const unsigned long module_cert_size = 0;
const u8 system_certificate_list[] = { }; const u8 system_certificate_list[] = { };
const unsigned long system_certificate_list_size = sizeof (system_certificate_list); const unsigned long system_certificate_list_size = sizeof (system_certificate_list);
@ -447,16 +31,6 @@ unsigned int shipped_regdb_certs_len = sizeof (shipped_regdb_certs);
/*
* Generate_dummies.c will otherwise pull in <linux/rcutree.h>
* that clashes with rcutiny.h.
*/
void rcu_barrier(void)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/filter.h> #include <linux/filter.h>
#include <linux/jump_label.h> /* for DEFINE_STATIC_KEY_FALSE */ #include <linux/jump_label.h> /* for DEFINE_STATIC_KEY_FALSE */
@ -495,16 +69,6 @@ __init int net_sysctl_init(void)
} }
#include <linux/proc_fs.h>
struct proc_dir_entry * proc_create_net_data(const char * name,umode_t mode,struct proc_dir_entry * parent,const struct seq_operations * ops,unsigned int state_size,void * data)
{
static struct proc_dir_entry _proc_dir_entry;
lx_emul_trace(__func__);
return &_proc_dir_entry;
}
#include <linux/fs.h> #include <linux/fs.h>
unsigned int get_next_ino(void) unsigned int get_next_ino(void)
@ -552,14 +116,6 @@ int kobject_uevent_env(struct kobject * kobj,enum kobject_action action,char * e
} }
#include <linux/sched.h>
void sched_set_fifo(struct task_struct * p)
{
lx_emul_trace(__func__);
}
#include <linux/moduleparam.h> #include <linux/moduleparam.h>
void kernel_param_lock(struct module * mod) void kernel_param_lock(struct module * mod)
@ -576,9 +132,6 @@ void kernel_param_unlock(struct module * mod)
} }
unsigned long lpj_fine = 0;
#include <linux/pid.h> #include <linux/pid.h>
void put_pid(struct pid * pid) void put_pid(struct pid * pid)
@ -659,38 +212,6 @@ int verify_pkcs7_signature(const void *data, size_t len,
#include <acpi/acpi_bus.h> #include <acpi/acpi_bus.h>
#include <acpi/acpixf.h> #include <acpi/acpixf.h>
int acpi_device_modalias(struct device *d, char * s, int i)
{
lx_emul_trace_and_stop(__func__);
}
int acpi_device_uevent_modalias(struct device *d, struct kobj_uevent_env *k)
{
lx_emul_trace_and_stop(__func__);
}
int acpi_dma_configure_id(struct device *dev,
enum dev_dma_attr attr,
const u32 *input_id)
{
lx_emul_trace_and_stop(__func__);
}
bool acpi_driver_match_device(struct device *dev, const struct device_driver *drv)
{
lx_emul_trace_and_stop(__func__);
}
union acpi_object *acpi_evaluate_dsm(acpi_handle handle, const guid_t *guid,
u64 rev, u64 func, union acpi_object *argv4)
{
return NULL;
}
acpi_status acpi_evaluate_object(acpi_handle handle, acpi_status acpi_evaluate_object(acpi_handle handle,
acpi_string pathname, acpi_string pathname,
@ -701,39 +222,16 @@ acpi_status acpi_evaluate_object(acpi_handle handle,
} }
enum dev_dma_attr acpi_get_dma_attr(struct acpi_device *adev)
{
lx_emul_trace_and_stop(__func__);
}
acpi_status acpi_get_handle(acpi_handle parent,acpi_string pathname,acpi_handle * ret_handle) acpi_status acpi_get_handle(acpi_handle parent,acpi_string pathname,acpi_handle * ret_handle)
{ {
lx_emul_trace_and_stop(__func__); lx_emul_trace_and_stop(__func__);
} }
int acpi_platform_notify(struct device *dev, enum kobject_action action)
{
return 0;
}
bool is_acpi_device_node(const struct fwnode_handle *fwnode)
{
return false;
}
#include <linux/pci.h> #include <linux/pci.h>
const struct attribute_group pci_dev_acpi_attr_group; const struct attribute_group pci_dev_acpi_attr_group;
int pci_acpi_program_hp_params(struct pci_dev *dev)
{
return -ENODEV;
}
struct irq_domain *pci_host_bridge_acpi_msi_domain(struct pci_bus *bus) struct irq_domain *pci_host_bridge_acpi_msi_domain(struct pci_bus *bus)
{ {
return NULL; return NULL;

View File

@ -1,7 +1,7 @@
/* /*
* \brief Dummy definitions of Linux Kernel functions * \brief Dummy definitions of Linux Kernel functions
* \author Automatically generated file - do no edit * \author Automatically generated file - do no edit
* \date 2022-02-28 * \date 2022-05-06
*/ */
#include <lx_emul.h> #include <lx_emul.h>
@ -47,14 +47,6 @@ unsigned long __fdget(unsigned int fd)
} }
#include <linux/gfp.h>
unsigned long __get_free_pages(gfp_t gfp_mask,unsigned int order)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/file.h> #include <linux/file.h>
int __get_unused_fd_flags(unsigned flags,unsigned long nofile) int __get_unused_fd_flags(unsigned flags,unsigned long nofile)
@ -174,14 +166,6 @@ struct file * alloc_file_pseudo(struct inode * inode,struct vfsmount * mnt,const
} }
#include <linux/msi.h>
struct msi_desc * alloc_msi_entry(struct device * dev,int nvec,const struct irq_affinity_desc * affinity)
{
lx_emul_trace_and_stop(__func__);
}
#include <crypto/arc4.h> #include <crypto/arc4.h>
void arc4_crypt(struct arc4_ctx * ctx,u8 * out,const u8 * in,unsigned int len) void arc4_crypt(struct arc4_ctx * ctx,u8 * out,const u8 * in,unsigned int len)
@ -400,14 +384,6 @@ void fput(struct file * file)
} }
#include <linux/msi.h>
void free_msi_entry(struct msi_desc * entry)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/sched/user.h> #include <linux/sched/user.h>
void free_uid(struct user_struct * up) void free_uid(struct user_struct * up)
@ -692,22 +668,6 @@ unsigned long long memparse(const char * ptr,char ** retptr)
} }
#include <linux/msi.h>
int msi_domain_alloc_irqs(struct irq_domain * domain,struct device * dev,int nvec)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/msi.h>
void msi_domain_free_irqs(struct irq_domain * domain,struct device * dev)
{
lx_emul_trace_and_stop(__func__);
}
#include <net/neighbour.h> #include <net/neighbour.h>
const struct nla_policy nda_policy[] = {}; const struct nla_policy nda_policy[] = {};
@ -734,6 +694,14 @@ loff_t no_llseek(struct file * file,loff_t offset,int whence)
} }
#include <linux/irq.h>
void note_interrupt(struct irq_desc * desc,irqreturn_t action_ret)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/proc_fs.h> #include <linux/proc_fs.h>
int open_related_ns(struct ns_common * ns,struct ns_common * (* get_ns)(struct ns_common * ns)) int open_related_ns(struct ns_common * ns,struct ns_common * (* get_ns)(struct ns_common * ns))
@ -1205,46 +1173,6 @@ void synchronize_srcu(struct srcu_struct * ssp)
} }
#include <linux/sysfs.h>
void sysfs_delete_link(struct kobject * kobj,struct kobject * targ,const char * name)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/sysfs.h>
int sysfs_emit(char * buf,const char * fmt,...)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/sysfs.h>
int sysfs_emit_at(char * buf,int at,const char * fmt,...)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/sysfs.h>
bool sysfs_remove_file_self(struct kobject * kobj,const struct attribute * attr)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/sysfs.h>
void sysfs_remove_group(struct kobject * kobj,const struct attribute_group * grp)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/sysfs.h> #include <linux/sysfs.h>
int sysfs_rename_dir_ns(struct kobject * kobj,const char * new_name,const void * new_ns) int sysfs_rename_dir_ns(struct kobject * kobj,const char * new_name,const void * new_ns)
@ -1277,6 +1205,14 @@ void tasklet_kill(struct tasklet_struct * t)
} }
#include <linux/vt_kern.h>
void unblank_screen(void)
{
lx_emul_trace_and_stop(__func__);
}
#include <linux/fs.h> #include <linux/fs.h>
int unregister_filesystem(struct file_system_type * fs) int unregister_filesystem(struct file_system_type * fs)

View File

@ -19,236 +19,15 @@
#include <asm-generic/delay.h> #include <asm-generic/delay.h>
#include <linux/delay.h>
void __const_udelay(unsigned long xloops) void __const_udelay(unsigned long xloops)
{ {
lx_emul_time_udelay(xloops / 0x10C7UL); unsigned long usecs = xloops / 0x10C7UL;
} if (usecs < 100)
lx_emul_time_udelay(usecs);
else
void __udelay(unsigned long usecs) usleep_range(usecs, usecs * 10);
{
lx_emul_time_udelay(usecs);
}
#include <linux/cpumask.h>
atomic_t __num_online_cpus = ATOMIC_INIT(1);
#include <linux/dma-mapping.h>
dma_addr_t dma_map_page_attrs(struct device * dev,
struct page * page,
size_t offset,
size_t size,
enum dma_data_direction dir,
unsigned long attrs)
{
dma_addr_t const dma_addr = page_to_phys(page);
unsigned long const virt_addr = (unsigned long)page_to_virt(page);
lx_emul_mem_cache_clean_invalidate((void *)(virt_addr + offset), size);
return dma_addr + offset;
}
#include <linux/dmapool.h>
struct dma_pool {
size_t size;
size_t align;
};
void * dma_pool_alloc(struct dma_pool * pool, gfp_t mem_flags, dma_addr_t * handle)
{
void * ret =
lx_emul_mem_alloc_aligned_uncached(pool->size, pool->align);
*handle = lx_emul_mem_dma_addr(ret);
return ret;
}
struct dma_pool * dma_pool_create(const char * name,
struct device * dev,
size_t size,
size_t align,
size_t boundary)
{
struct dma_pool * pool = kmalloc(sizeof(struct dma_pool), GFP_KERNEL);
pool->size = size;
pool->align = align;
return pool;
}
void dma_pool_free(struct dma_pool * pool,void * vaddr,dma_addr_t dma)
{
lx_emul_mem_free(vaddr);
}
struct dma_pool *dmam_pool_create(const char *name,
struct device *dev,
size_t size,
size_t align,
size_t allocation)
{
/*
* Only take care of allocating the pool because
* we do not detach the driver anyway.
*/
return dma_pool_create(name, dev, size, align, 0);
}
#include <linux/dma-mapping.h>
int dma_supported(struct device * dev,u64 mask)
{
lx_emul_trace(__func__);
return 1;
}
#include <linux/dma-mapping.h>
void dma_unmap_page_attrs(struct device * dev,
dma_addr_t addr,
size_t size,
enum dma_data_direction dir,
unsigned long attrs)
{
unsigned long const virt_addr = lx_emul_mem_virt_addr((void*)addr);
if (!virt_addr)
return;
if (dir == DMA_FROM_DEVICE)
lx_emul_mem_cache_invalidate((void *)virt_addr, size);
}
#include <linux/dma-mapping.h>
void dma_sync_single_for_cpu(struct device *dev, dma_addr_t addr,
size_t size, enum dma_data_direction dir)
{
unsigned long const virt_addr = lx_emul_mem_virt_addr((void*)addr);
if (!virt_addr)
return;
lx_emul_mem_cache_invalidate((void *)virt_addr, size);
}
#include <linux/dma-mapping.h>
void dma_sync_single_for_device(struct device *dev, dma_addr_t addr,
size_t size, enum dma_data_direction dir)
{
unsigned long const virt_addr = lx_emul_mem_virt_addr((void*)addr);
if (!virt_addr)
return;
lx_emul_mem_cache_clean_invalidate((void *)virt_addr, size);
}
#include <linux/slab.h>
void * kmalloc_order(size_t size, gfp_t flags, unsigned int order)
{
return kmalloc(size, flags);
}
#include <linux/fs.h>
#include <linux/mount.h>
#include <linux/slab.h>
int simple_pin_fs(struct file_system_type * type, struct vfsmount ** mount, int * count)
{
*mount = kmalloc(sizeof(struct vfsmount), GFP_KERNEL);
return 0;
}
#include <linux/fs.h>
void simple_release_fs(struct vfsmount ** mount,int * count)
{
kfree(*mount);
}
#include <linux/fs.h>
struct inode * alloc_anon_inode(struct super_block * s)
{
return kmalloc(sizeof(struct inode), GFP_KERNEL);
}
#include <linux/interrupt.h>
// softirq.c
void tasklet_setup(struct tasklet_struct * t,
void (* callback)(struct tasklet_struct *))
{
t->next = NULL;
t->state = 0;
atomic_set(&t->count, 0);
t->callback = callback;
t->use_callback = true;
t->data = 0;
}
void __tasklet_schedule(struct tasklet_struct * t)
{
if (test_and_clear_bit(TASKLET_STATE_SCHED, &t->state))
t->callback(t);
}
void __tasklet_hi_schedule(struct tasklet_struct * t)
{
if (test_and_clear_bit(TASKLET_STATE_SCHED, &t->state))
t->callback(t);
}
#include <linux/rcupdate.h>
void call_rcu(struct rcu_head * head,rcu_callback_t func)
{
enum { KVFREE_RCU_OFFSET = 4096, };
if (func < (rcu_callback_t)KVFREE_RCU_OFFSET) {
kvfree((void*)head - (unsigned long)func);
return;
}
func(head);
}
#include <asm-generic/logic_io.h>
void __iomem * ioremap(resource_size_t phys_addr, unsigned long size)
{
return lx_emul_io_mem_map(phys_addr, size);
}
#include <asm-generic/logic_io.h>
void iounmap(volatile void __iomem * addr)
{
(void)addr;
} }
@ -352,16 +131,6 @@ struct inode * new_inode_pseudo(struct super_block * sb)
} }
#include <linux/sysfs.h>
int sysfs_create_dir_ns(struct kobject * kobj,const void * ns)
{
lx_emul_trace(__func__);
kobj->sd = kzalloc(sizeof(*kobj->sd), GFP_KERNEL);
return 0;
}
#include <linux/firmware.h> #include <linux/firmware.h>
#if 0 #if 0
@ -530,30 +299,6 @@ int task_work_add(struct task_struct * task,struct callback_head * work,enum tas
} }
#include <linux/vmalloc.h>
void vfree(const void * addr)
{
kfree(addr);
}
#include <linux/vmalloc.h>
void * vmalloc(unsigned long size)
{
return kmalloc(size, GFP_KERNEL);
}
#include <linux/vmalloc.h>
void * vzalloc(unsigned long size)
{
return kzalloc(size, GFP_KERNEL);
}
#include <linux/interrupt.h> #include <linux/interrupt.h>
void __raise_softirq_irqoff(unsigned int nr) void __raise_softirq_irqoff(unsigned int nr)
@ -577,14 +322,6 @@ void kfree_sensitive(const void *p)
} }
#include <linux/gfp.h>
void free_pages(unsigned long addr,unsigned int order)
{
__free_pages(virt_to_page((void *)addr), order);
}
#include <linux/gfp.h> #include <linux/gfp.h>
#include <linux/slab.h> #include <linux/slab.h>
@ -721,7 +458,8 @@ int __must_check get_random_bytes_arch(void *buf, int nbytes)
void get_random_bytes(void *buf, int nbytes) void get_random_bytes(void *buf, int nbytes)
{ {
get_random_bytes_arch(buf, nbytes); int const err = get_random_bytes_arch(buf, nbytes);
(void)err;
} }
@ -745,7 +483,6 @@ void *page_frag_alloc_align(struct page_frag_cache *nc,
unsigned int fragsz, gfp_t gfp_mask, unsigned int fragsz, gfp_t gfp_mask,
unsigned int align_mask) unsigned int align_mask)
{ {
(void)nc;
unsigned int const order = fragsz / PAGE_SIZE; unsigned int const order = fragsz / PAGE_SIZE;
struct page *page = __alloc_pages(gfp_mask, order, 0, NULL); struct page *page = __alloc_pages(gfp_mask, order, 0, NULL);

View File

@ -0,0 +1,24 @@
arch/x86/include/asm/checksum_32.h
arch/x86/include/asm/cmpxchg_32.h
arch/x86/include/asm/numa_32.h
arch/x86/include/asm/page_32.h
arch/x86/include/asm/page_32_types.h
arch/x86/include/asm/pgtable-2level_types.h
arch/x86/include/asm/pgtable_32_areas.h
arch/x86/include/asm/pgtable_32_types.h
arch/x86/include/asm/user_32.h
arch/x86/include/uapi/asm/posix_types_32.h
certs/system_keyring.c
include/asm-generic/asm-prototypes.h
include/asm-generic/bitops/fls64.h
include/asm-generic/pgtable-nopmd.h
include/asm-generic/pgtable-nopud.h
include/crypto/pkcs7.h
include/crypto/public_key.h
include/keys/asymmetric-type.h
include/keys/system_keyring.h
include/linux/key-type.h
include/linux/keyctl.h
include/linux/oid_registry.h
include/uapi/linux/keyctl.h
kernel/time/tick-broadcast.c

File diff suppressed because it is too large Load Diff