The ::unload field is a function pointer, so it should be u32 for 32-bit, u64 for 64-bit. Add a prototype for it in the native efi_loaded_image_t type. Also change type of parent_handle and device_handle from void * to efi_handle_t for documentation purposes. The unload method is not used, so no functional change.
Showing the changes to include/linux (1 of 1 file). Show all
Unified · Split
| @@ -824,7 +824,7 @@ typedef struct { · 823 unmodified lines | |||
| 824 | __aligned_u64 image_size; | 824 | __aligned_u64 image_size; |
| 825 | unsigned int image_code_type; | 825 | unsigned int image_code_type; |
| 826 | unsigned int image_data_type; | 826 | unsigned int image_data_type; |
| 827 | unsigned long unload; | 827 | u32 unload; |
| 828 | } efi_loaded_image_32_t; | 828 | } efi_loaded_image_32_t; |
| 829 | 829 | ||
| 830 | typedef struct { | 830 | typedef struct { |
| @@ -840,14 +840,14 @@ typedef struct { · 9 unmodified lines | |||
| 840 | __aligned_u64 image_size; | 840 | __aligned_u64 image_size; |
| 841 | unsigned int image_code_type; | 841 | unsigned int image_code_type; |
| 842 | unsigned int image_data_type; | 842 | unsigned int image_data_type; |
| 843 | unsigned long unload; | 843 | u64 unload; |
| 844 | } efi_loaded_image_64_t; | 844 | } efi_loaded_image_64_t; |
| 845 | 845 | ||
| 846 | typedef struct { | 846 | typedef struct { |
| 847 | u32 revision; | 847 | u32 revision; |
| 848 | void *parent_handle; | 848 | efi_handle_t parent_handle; |
| 849 | efi_system_table_t *system_table; | 849 | efi_system_table_t *system_table; |
| 850 | void *device_handle; | 850 | efi_handle_t device_handle; |
| 851 | void *file_path; | 851 | void *file_path; |
| 852 | void *reserved; | 852 | void *reserved; |
| 853 | u32 load_options_size; | 853 | u32 load_options_size; |
| @@ -856,7 +856,7 @@ typedef struct { · 2 unmodified lines | |||
| 856 | __aligned_u64 image_size; | 856 | __aligned_u64 image_size; |
| 857 | unsigned int image_code_type; | 857 | unsigned int image_code_type; |
| 858 | unsigned int image_data_type; | 858 | unsigned int image_data_type; |
| 859 | unsigned long unload; | 859 | efi_status_t (*unload)(efi_handle_t image_handle); |
| 860 | } efi_loaded_image_t; | 860 | } efi_loaded_image_t; |
| 861 | 861 | ||
| 862 | 862 | ||