1 1.1 riastrad /* $NetBSD: ls.h,v 1.2 2021/12/18 23:45:32 riastradh Exp $ */ 2 1.1 riastrad 3 1.1 riastrad /* SPDX-License-Identifier: MIT */ 4 1.1 riastrad #ifndef __NVFW_LS_H__ 5 1.1 riastrad #define __NVFW_LS_H__ 6 1.1 riastrad #include <core/os.h> 7 1.1 riastrad struct nvkm_subdev; 8 1.1 riastrad 9 1.1 riastrad struct nvfw_ls_desc_head { 10 1.1 riastrad u32 descriptor_size; 11 1.1 riastrad u32 image_size; 12 1.1 riastrad u32 tools_version; 13 1.1 riastrad u32 app_version; 14 1.1 riastrad char date[64]; 15 1.1 riastrad u32 bootloader_start_offset; 16 1.1 riastrad u32 bootloader_size; 17 1.1 riastrad u32 bootloader_imem_offset; 18 1.1 riastrad u32 bootloader_entry_point; 19 1.1 riastrad u32 app_start_offset; 20 1.1 riastrad u32 app_size; 21 1.1 riastrad u32 app_imem_offset; 22 1.1 riastrad u32 app_imem_entry; 23 1.1 riastrad u32 app_dmem_offset; 24 1.1 riastrad u32 app_resident_code_offset; 25 1.1 riastrad u32 app_resident_code_size; 26 1.1 riastrad u32 app_resident_data_offset; 27 1.1 riastrad u32 app_resident_data_size; 28 1.1 riastrad }; 29 1.1 riastrad 30 1.1 riastrad struct nvfw_ls_desc { 31 1.1 riastrad struct nvfw_ls_desc_head head; 32 1.1 riastrad u32 nb_overlays; 33 1.1 riastrad struct { 34 1.1 riastrad u32 start; 35 1.1 riastrad u32 size; 36 1.1 riastrad } load_ovl[64]; 37 1.1 riastrad u32 compressed; 38 1.1 riastrad }; 39 1.1 riastrad 40 1.1 riastrad const struct nvfw_ls_desc *nvfw_ls_desc(struct nvkm_subdev *, const void *); 41 1.1 riastrad 42 1.1 riastrad struct nvfw_ls_desc_v1 { 43 1.1 riastrad struct nvfw_ls_desc_head head; 44 1.1 riastrad u32 nb_imem_overlays; 45 1.1 riastrad u32 nb_dmem_overlays; 46 1.1 riastrad struct { 47 1.1 riastrad u32 start; 48 1.1 riastrad u32 size; 49 1.1 riastrad } load_ovl[64]; 50 1.1 riastrad u32 compressed; 51 1.1 riastrad }; 52 1.1 riastrad 53 1.1 riastrad const struct nvfw_ls_desc_v1 * 54 1.1 riastrad nvfw_ls_desc_v1(struct nvkm_subdev *, const void *); 55 1.1 riastrad #endif 56