/* * Copyright 2023 Red Hat Inc. * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), * to deal in the Software without restriction, including without limitation * the rights to use, copy, modify, merge, publish, distribute, sublicense, * and/or sell copies of the Software, and to permit persons to whom the * Software is furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR * OTHER DEALINGS IN THE SOFTWARE. */ #include "priv.h" #include <subdev/bios.h> #include <subdev/bios/pmu.h> #include <nvfw/fw.h> nvfw_falcon_appif_hdr; nvfw_falcon_appif; nvfw_falcon_appif_dmemmapper; struct nvfw_fwsec_frts_cmd { … }; static int nvkm_gsp_fwsec_patch(struct nvkm_gsp *gsp, struct nvkm_falcon_fw *fw, u32 if_offset, u32 init_cmd) { … } nvfw_falcon_ucode_desc; static int nvkm_gsp_fwsec_v2(struct nvkm_gsp *gsp, const char *name, const struct nvkm_falcon_ucode_desc_v2 *desc, u32 size, u32 init_cmd, struct nvkm_falcon_fw *fw) { … } static int nvkm_gsp_fwsec_v3(struct nvkm_gsp *gsp, const char *name, const struct nvkm_falcon_ucode_desc_v3 *desc, u32 size, u32 init_cmd, struct nvkm_falcon_fw *fw) { … } static int nvkm_gsp_fwsec(struct nvkm_gsp *gsp, const char *name, u32 init_cmd) { … } int nvkm_gsp_fwsec_sb(struct nvkm_gsp *gsp) { … } int nvkm_gsp_fwsec_frts(struct nvkm_gsp *gsp) { … }