From: Ville Syrjälä <ville.syrjala@xxxxxxxxxxxxxxx> drm/nouveau/dispnv04/overlay.c:496:1: warning: symbol 'nouveau_overlay_init' was not declared. Should it be static? drm/nouveau/nouveau_connector.c:63:5: warning: symbol 'nouveau_hdmimhz' was not declared. Should it be static? drm/nouveau/nouveau_display.c:96:1: warning: symbol 'nouveau_display_scanoutpos_head' was not declared. Should it be static? drm/nouveau/nv10_fence.c:70:1: warning: symbol 'nv10_fence_context_new' was not declared. Should it be static? drm/nouveau/nvif/client.c:58:26: warning: symbol 'nvif_drivers' was not declared. Should it be static? drm/nouveau/nvkm/core/firmware.c:34:1: warning: symbol 'nvkm_firmware_get' was not declared. Should it be static? drm/nouveau/nvkm/core/firmware.c:58:1: warning: symbol 'nvkm_firmware_put' was not declared. Should it be static? drm/nouveau/nvkm/engine/device/user.c:330:1: warning: symbol 'nvkm_udevice_new' was not declared. Should it be static? drm/nouveau/nvkm/engine/disp/channv50.c:157:1: warning: symbol 'nv50_disp_chan_rd32' was not declared. Should it be static? drm/nouveau/nvkm/engine/disp/channv50.c:167:1: warning: symbol 'nv50_disp_chan_wr32' was not declared. Should it be static? drm/nouveau/nvkm/engine/disp/channv50.c:177:1: warning: symbol 'nv50_disp_chan_ntfy' was not declared. Should it be static? drm/nouveau/nvkm/engine/disp/channv50.c:193:1: warning: symbol 'nv50_disp_chan_map' was not declared. Should it be static? drm/nouveau/nvkm/engine/disp/coreg94.c:30:1: warning: symbol 'g94_disp_core_mthd_sor' was not declared. Should it be static? drm/nouveau/nvkm/engine/disp/coregp104.c:63:1: warning: symbol 'gp104_disp_core_func' was not declared. Should it be static? drm/nouveau/nvkm/engine/disp/rootnv50.c:70:1: warning: symbol 'nv50_disp_root_mthd_' was not declared. Should it be static? drm/nouveau/nvkm/engine/disp/sorg94.c:49:1: warning: symbol 'g94_sor_output_new' was not declared. Should it be static? drm/nouveau/nvkm/engine/fifo/chang84.c:133:1: warning: symbol 'g84_fifo_chan_engine_init' was not declared. Should it be static? drm/nouveau/nvkm/engine/fifo/chang84.c:174:1: warning: symbol 'g84_fifo_chan_object_ctor' was not declared. Should it be static? drm/nouveau/nvkm/engine/gr/ctxgf117.c:222:1: warning: symbol 'gf117_grctx_generate_main' was not declared. Should it be static? drm/nouveau/nvkm/engine/gr/ctxgm107.c:937:1: warning: symbol 'gm107_grctx_generate_tpcid' was not declared. Should it be static? drm/nouveau/nvkm/engine/gr/ctxnv50.c:255:1: warning: symbol 'nv50_grctx_fill' was not declared. Should it be static? drm/nouveau/nvkm/engine/gr/ctxnv50.c:265:1: warning: symbol 'nv50_grctx_init' was not declared. Should it be static? drm/nouveau/nvkm/engine/gr/gf100.c:1388:1: warning: symbol 'gf100_gr_init_fw' was not declared. Should it be static? drm/nouveau/nvkm/engine/gr/gf100.c:1705:1: warning: symbol 'gf100_gr_init_' was not declared. Should it be static? drm/nouveau/nvkm/engine/gr/gf117.c:106:1: warning: symbol 'gf117_gr_fecs_ucode' was not declared. Should it be static? drm/nouveau/nvkm/engine/gr/gf117.c:116:1: warning: symbol 'gf117_gr_gpccs_ucode' was not declared. Should it be static? drm/nouveau/nvkm/engine/gr/gm107.c:312:1: warning: symbol 'gm107_gr_init' was not declared. Should it be static? drm/nouveau/nvkm/engine/pm/base.c:703:1: warning: symbol 'nvkm_perfsrc_new' was not declared. Should it be static? drm/nouveau/nvkm/engine/pm/base.c:74:21: warning: symbol 'nvkm_perfsig_find' was not declared. Should it be static? drm/nouveau/nvkm/engine/pm/gf100.c:106:1: warning: symbol 'gf100_pm_part' was not declared. Should it be static? drm/nouveau/nvkm/subdev/bios/fan.c:29:1: warning: symbol 'nvbios_fan_table' was not declared. Should it be static? drm/nouveau/nvkm/subdev/bios/fan.c:56:1: warning: symbol 'nvbios_fan_entry' was not declared. Should it be static? drm/nouveau/nvkm/subdev/clk/gt215.c:184:1: warning: symbol 'gt215_clk_info' was not declared. Should it be static? drm/nouveau/nvkm/subdev/fb/ramgt215.c:153:1: warning: symbol 'gt215_link_train' was not declared. Should it be static? drm/nouveau/nvkm/subdev/fb/ramgt215.c:271:1: warning: symbol 'gt215_link_train_init' was not declared. Should it be static? drm/nouveau/nvkm/subdev/fb/ramgt215.c:337:1: warning: symbol 'gt215_link_train_fini' was not declared. Should it be static? drm/nouveau/nvkm/subdev/fb/ramgt215.c:99:1: warning: symbol 'gt215_link_train_calc' was not declared. Should it be static? drm/nouveau/nvkm/subdev/fb/sddr2.c:60:1: warning: symbol 'nvkm_sddr2_calc' was not declared. Should it be static? drm/nouveau/nvkm/subdev/fb/sddr3.c:69:1: warning: symbol 'nvkm_sddr3_calc' was not declared. Should it be static? drm/nouveau/nvkm/subdev/gpio/gk104.c:41:1: warning: symbol 'gk104_gpio_intr_mask' was not declared. Should it be static? drm/nouveau/nvkm/subdev/i2c/aux.c:78:1: warning: symbol 'nvkm_i2c_aux_i2c_algo' was not declared. Should it be static? drm/nouveau/nvkm/subdev/iccsense/base.c:332:25: warning: symbol 'iccsense_func' was not declared. Should it be static? drm/nouveau/nvkm/subdev/instmem/base.c:108:1: warning: symbol 'nvkm_instobj_func' was not declared. Should it be static? drm/nouveau/nvkm/subdev/instmem/base.c:160:1: warning: symbol 'nvkm_instobj_func_slow' was not declared. Should it be static? drm/nouveau/nvkm/subdev/mc/g84.c:38:1: warning: symbol 'g84_mc_intr' was not declared. Should it be static? ../drivers/gpu/drm/nouveau/nvkm/subdev/secboot/gm200.c:1206:20: warning: Variable length array is used. drm/nouveau/nvkm/subdev/secboot/gm200.c:1368:1: warning: symbol 'gm200_secboot_fini' was not declared. Should it be static? ../drivers/gpu/drm/nouveau/nvkm/subdev/secboot/gm200.c:779:42: warning: Variable length array is used. drm/nouveau/nvkm/subdev/volt/gk104.c:38:1: warning: symbol 'gk104_volt_get' was not declared. Should it be static? drm/nouveau/nvkm/subdev/volt/gk104.c:51:1: warning: symbol 'gk104_volt_set' was not declared. Should it be static? drm/nouveau/nvkm/subdev/volt/gm20b.c:28:23: warning: symbol 'gm20b_cvb_coef' was not declared. Should it be static? drm/nouveau/nvkm/subdev/volt/gm20b.c:61:11: warning: symbol 'speedo_to_vmin' was not declared. Should it be static? drm/nouveau/nvkm/subdev/volt/gpio.c:35:1: warning: symbol 'nvkm_voltgpio_get' was not declared. Should it be static? drm/nouveau/nvkm/subdev/volt/gpio.c:54:1: warning: symbol 'nvkm_voltgpio_set' was not declared. Should it be static? drm/nouveau/nvkm/subdev/volt/gpio.c:71:1: warning: symbol 'nvkm_voltgpio_init' was not declared. Should it be static? Cc: Ben Skeggs <bskeggs@xxxxxxxxxx> Signed-off-by: Ville Syrjälä <ville.syrjala@xxxxxxxxxxxxxxx> --- drivers/gpu/drm/nouveau/dispnv04/overlay.c | 2 +- drivers/gpu/drm/nouveau/nouveau_connector.c | 2 +- drivers/gpu/drm/nouveau/nouveau_display.c | 2 +- drivers/gpu/drm/nouveau/nv10_fence.c | 2 +- drivers/gpu/drm/nouveau/nvif/client.c | 2 +- drivers/gpu/drm/nouveau/nvkm/core/firmware.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/device/user.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/disp/channv50.c | 8 ++++---- drivers/gpu/drm/nouveau/nvkm/engine/disp/coreg94.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/disp/coregp104.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/disp/rootnv50.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/disp/sorg94.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/fifo/chang84.c | 4 ++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf117.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxnv50.c | 1 + drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c | 4 ++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/gf117.c | 4 ++-- drivers/gpu/drm/nouveau/nvkm/engine/gr/gm107.c | 2 +- drivers/gpu/drm/nouveau/nvkm/engine/pm/base.c | 4 ++-- drivers/gpu/drm/nouveau/nvkm/engine/pm/gf100.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/bios/fan.c | 4 ++-- drivers/gpu/drm/nouveau/nvkm/subdev/clk/gt215.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/fb/ramgt215.c | 8 ++++---- drivers/gpu/drm/nouveau/nvkm/subdev/fb/sddr2.c | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/fb/sddr3.c | 1 + drivers/gpu/drm/nouveau/nvkm/subdev/gpio/gk104.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/i2c/aux.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/iccsense/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/instmem/base.c | 4 ++-- drivers/gpu/drm/nouveau/nvkm/subdev/mc/g84.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/secboot/gm200.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/volt/gk104.c | 4 ++-- drivers/gpu/drm/nouveau/nvkm/subdev/volt/gm20b.c | 4 ++-- drivers/gpu/drm/nouveau/nvkm/subdev/volt/gpio.c | 1 + 35 files changed, 49 insertions(+), 44 deletions(-) diff --git a/drivers/gpu/drm/nouveau/dispnv04/overlay.c b/drivers/gpu/drm/nouveau/dispnv04/overlay.c index ec444eac6258..486401f6dab8 100644 --- a/drivers/gpu/drm/nouveau/dispnv04/overlay.c +++ b/drivers/gpu/drm/nouveau/dispnv04/overlay.c @@ -27,6 +27,7 @@ #include <drm/drm_crtc.h> #include <drm/drm_fourcc.h> +#include "disp.h" #include "nouveau_drv.h" #include "nouveau_bo.h" @@ -34,7 +35,6 @@ #include "nouveau_display.h" #include "nvreg.h" - struct nouveau_plane { struct drm_plane base; bool flip; diff --git a/drivers/gpu/drm/nouveau/nouveau_connector.c b/drivers/gpu/drm/nouveau/nouveau_connector.c index c1084088f9e4..61f3f67b5f09 100644 --- a/drivers/gpu/drm/nouveau/nouveau_connector.c +++ b/drivers/gpu/drm/nouveau/nouveau_connector.c @@ -60,7 +60,7 @@ int nouveau_duallink = 1; module_param_named(duallink, nouveau_duallink, int, 0400); MODULE_PARM_DESC(hdmimhz, "Force a maximum HDMI pixel clock (in MHz)"); -int nouveau_hdmimhz = 0; +static int nouveau_hdmimhz; module_param_named(hdmimhz, nouveau_hdmimhz, int, 0400); struct nouveau_encoder * diff --git a/drivers/gpu/drm/nouveau/nouveau_display.c b/drivers/gpu/drm/nouveau/nouveau_display.c index afbf557b23d4..b60ee21f4571 100644 --- a/drivers/gpu/drm/nouveau/nouveau_display.c +++ b/drivers/gpu/drm/nouveau/nouveau_display.c @@ -92,7 +92,7 @@ calc(int blanks, int blanke, int total, int line) return line; } -int +static int nouveau_display_scanoutpos_head(struct drm_crtc *crtc, int *vpos, int *hpos, ktime_t *stime, ktime_t *etime) { diff --git a/drivers/gpu/drm/nouveau/nv10_fence.c b/drivers/gpu/drm/nouveau/nv10_fence.c index 4e3de34ff6f4..619f79de5859 100644 --- a/drivers/gpu/drm/nouveau/nv10_fence.c +++ b/drivers/gpu/drm/nouveau/nv10_fence.c @@ -66,7 +66,7 @@ nv10_fence_context_del(struct nouveau_channel *chan) nouveau_fence_context_free(&fctx->base); } -int +static int nv10_fence_context_new(struct nouveau_channel *chan) { struct nv10_fence_chan *fctx; diff --git a/drivers/gpu/drm/nouveau/nvif/client.c b/drivers/gpu/drm/nouveau/nvif/client.c index 1ee9294eca2e..29c20dfd894d 100644 --- a/drivers/gpu/drm/nouveau/nvif/client.c +++ b/drivers/gpu/drm/nouveau/nvif/client.c @@ -55,7 +55,7 @@ nvif_client_fini(struct nvif_client *client) } } -const struct nvif_driver * +static const struct nvif_driver * nvif_drivers[] = { #ifdef __KERNEL__ &nvif_driver_nvkm, diff --git a/drivers/gpu/drm/nouveau/nvkm/core/firmware.c b/drivers/gpu/drm/nouveau/nvkm/core/firmware.c index 34ecd4a7e0c1..058ff46b5f16 100644 --- a/drivers/gpu/drm/nouveau/nvkm/core/firmware.c +++ b/drivers/gpu/drm/nouveau/nvkm/core/firmware.c @@ -20,6 +20,7 @@ * DEALINGS IN THE SOFTWARE. */ #include <core/device.h> +#include <core/firmware.h> /** * nvkm_firmware_get - load firmware from the official nvidia/chip/ directory diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/device/user.c b/drivers/gpu/drm/nouveau/nvkm/engine/device/user.c index 79a8f71cf788..513ee6b79553 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/device/user.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/device/user.c @@ -326,7 +326,7 @@ nvkm_udevice = { .sclass = nvkm_udevice_child_get, }; -int +static int nvkm_udevice_new(const struct nvkm_oclass *oclass, void *data, u32 size, struct nvkm_object **pobject) { diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/disp/channv50.c b/drivers/gpu/drm/nouveau/nvkm/engine/disp/channv50.c index dd2953bc9264..26990d44ae75 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/disp/channv50.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/disp/channv50.c @@ -153,7 +153,7 @@ nv50_disp_chan_uevent = { .fini = nv50_disp_chan_uevent_fini, }; -int +static int nv50_disp_chan_rd32(struct nvkm_object *object, u64 addr, u32 *data) { struct nv50_disp_chan *chan = nv50_disp_chan(object); @@ -163,7 +163,7 @@ nv50_disp_chan_rd32(struct nvkm_object *object, u64 addr, u32 *data) return 0; } -int +static int nv50_disp_chan_wr32(struct nvkm_object *object, u64 addr, u32 data) { struct nv50_disp_chan *chan = nv50_disp_chan(object); @@ -173,7 +173,7 @@ nv50_disp_chan_wr32(struct nvkm_object *object, u64 addr, u32 data) return 0; } -int +static int nv50_disp_chan_ntfy(struct nvkm_object *object, u32 type, struct nvkm_event **pevent) { @@ -189,7 +189,7 @@ nv50_disp_chan_ntfy(struct nvkm_object *object, u32 type, return -EINVAL; } -int +static int nv50_disp_chan_map(struct nvkm_object *object, u64 *addr, u32 *size) { struct nv50_disp_chan *chan = nv50_disp_chan(object); diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/disp/coreg94.c b/drivers/gpu/drm/nouveau/nvkm/engine/disp/coreg94.c index 019379a3a01c..b94db5e68cab 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/disp/coreg94.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/disp/coreg94.c @@ -26,7 +26,7 @@ #include <nvif/class.h> -const struct nv50_disp_mthd_list +static const struct nv50_disp_mthd_list g94_disp_core_mthd_sor = { .mthd = 0x0040, .addr = 0x000008, diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/disp/coregp104.c b/drivers/gpu/drm/nouveau/nvkm/engine/disp/coregp104.c index 6922f4007b61..e356f87fbe60 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/disp/coregp104.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/disp/coregp104.c @@ -59,7 +59,7 @@ gp104_disp_core_init(struct nv50_disp_dmac *chan) return 0; } -const struct nv50_disp_dmac_func +static const struct nv50_disp_dmac_func gp104_disp_core_func = { .init = gp104_disp_core_init, .fini = gf119_disp_core_fini, diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/disp/rootnv50.c b/drivers/gpu/drm/nouveau/nvkm/engine/disp/rootnv50.c index 2f9cecd81d04..6424b396dcde 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/disp/rootnv50.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/disp/rootnv50.c @@ -66,7 +66,7 @@ nv50_disp_root_scanoutpos(NV50_DISP_MTHD_V0) return 0; } -int +static int nv50_disp_root_mthd_(struct nvkm_object *object, u32 mthd, void *data, u32 size) { union { diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/disp/sorg94.c b/drivers/gpu/drm/nouveau/nvkm/engine/disp/sorg94.c index 1bb9d661e9b3..bae51b5ba51d 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/disp/sorg94.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/disp/sorg94.c @@ -45,7 +45,7 @@ static const struct nvkm_output_func g94_sor_output_func = { }; -int +static int g94_sor_output_new(struct nvkm_disp *disp, int index, struct dcb_output *dcbE, struct nvkm_output **poutp) { diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/fifo/chang84.c b/drivers/gpu/drm/nouveau/nvkm/engine/fifo/chang84.c index aeb3387a3fb0..15a992b3580a 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/fifo/chang84.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/fifo/chang84.c @@ -129,7 +129,7 @@ g84_fifo_chan_engine_fini(struct nvkm_fifo_chan *base, } -int +static int g84_fifo_chan_engine_init(struct nvkm_fifo_chan *base, struct nvkm_engine *engine) { @@ -170,7 +170,7 @@ g84_fifo_chan_engine_ctor(struct nvkm_fifo_chan *base, return nvkm_object_bind(object, NULL, 0, &chan->engn[engn]); } -int +static int g84_fifo_chan_object_ctor(struct nvkm_fifo_chan *base, struct nvkm_object *object) { diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf117.c b/drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf117.c index c925ade5880e..74a64e3fd59a 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf117.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf117.c @@ -218,7 +218,7 @@ gf117_grctx_generate_attrib(struct gf100_grctx *info) } } -void +static void gf117_grctx_generate_main(struct gf100_gr *gr, struct gf100_grctx *info) { struct nvkm_device *device = gr->base.engine.subdev.device; diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c b/drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c index 6d3c5011e18c..4c4b5ab6e46d 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c @@ -933,7 +933,7 @@ gm107_grctx_generate_attrib(struct gf100_grctx *info) } } -void +static void gm107_grctx_generate_tpcid(struct gf100_gr *gr) { struct nvkm_device *device = gr->base.engine.subdev.device; diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxnv50.c b/drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxnv50.c index 1e13278cf306..c8bb9191f9a2 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxnv50.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxnv50.c @@ -106,6 +106,7 @@ #define CP_SEEK_2 0x00c800ff #include "ctxnv40.h" +#include "nv50.h" #include <subdev/fb.h> diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c b/drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c index 157919c788e6..eccdee04107d 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c @@ -1384,7 +1384,7 @@ gf100_gr_intr(struct nvkm_gr *base) nvkm_fifo_chan_put(device->fifo, flags, &chan); } -void +static void gf100_gr_init_fw(struct gf100_gr *gr, u32 fuc_base, struct gf100_gr_fuc *code, struct gf100_gr_fuc *data) { @@ -1701,7 +1701,7 @@ gf100_gr_oneinit(struct nvkm_gr *base) return 0; } -int +static int gf100_gr_init_(struct nvkm_gr *base) { struct gf100_gr *gr = gf100_gr(base); diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/gr/gf117.c b/drivers/gpu/drm/nouveau/nvkm/engine/gr/gf117.c index 70335f65c51e..0124e468086e 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/gr/gf117.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/gr/gf117.c @@ -102,7 +102,7 @@ gf117_gr_pack_mmio[] = { #include "fuc/hubgf117.fuc3.h" -struct gf100_gr_ucode +static struct gf100_gr_ucode gf117_gr_fecs_ucode = { .code.data = gf117_grhub_code, .code.size = sizeof(gf117_grhub_code), @@ -112,7 +112,7 @@ gf117_gr_fecs_ucode = { #include "fuc/gpcgf117.fuc3.h" -struct gf100_gr_ucode +static struct gf100_gr_ucode gf117_gr_gpccs_ucode = { .code.data = gf117_grgpc_code, .code.size = sizeof(gf117_grgpc_code), diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/gr/gm107.c b/drivers/gpu/drm/nouveau/nvkm/engine/gr/gm107.c index 45f965f608a7..2c67fac576d1 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/gr/gm107.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/gr/gm107.c @@ -308,7 +308,7 @@ gm107_gr_init_bios(struct gf100_gr *gr) } } -int +static int gm107_gr_init(struct gf100_gr *gr) { struct nvkm_device *device = gr->base.engine.subdev.device; diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/pm/base.c b/drivers/gpu/drm/nouveau/nvkm/engine/pm/base.c index 8616636ad7b4..dde89a4a0f5b 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/pm/base.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/pm/base.c @@ -71,7 +71,7 @@ nvkm_perfdom_find(struct nvkm_pm *pm, int di) return NULL; } -struct nvkm_perfsig * +static struct nvkm_perfsig * nvkm_perfsig_find(struct nvkm_pm *pm, u8 di, u8 si, struct nvkm_perfdom **pdom) { struct nvkm_perfdom *dom = *pdom; @@ -699,7 +699,7 @@ nvkm_pm_oclass_get(struct nvkm_oclass *oclass, int index, return 1; } -int +static int nvkm_perfsrc_new(struct nvkm_pm *pm, struct nvkm_perfsig *sig, const struct nvkm_specsrc *spec) { diff --git a/drivers/gpu/drm/nouveau/nvkm/engine/pm/gf100.c b/drivers/gpu/drm/nouveau/nvkm/engine/pm/gf100.c index d2901e9a7808..fe2532ee4145 100644 --- a/drivers/gpu/drm/nouveau/nvkm/engine/pm/gf100.c +++ b/drivers/gpu/drm/nouveau/nvkm/engine/pm/gf100.c @@ -102,7 +102,7 @@ gf100_pm_gpc[] = { {} }; -const struct nvkm_specdom +static const struct nvkm_specdom gf100_pm_part[] = { { 0xe0, (const struct nvkm_specsig[]) { { 0x0f, "part00_pbfb_00", gf100_pbfb_sources }, diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/bios/fan.c b/drivers/gpu/drm/nouveau/nvkm/subdev/bios/fan.c index 80fed7e78dcb..e2905815049b 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/bios/fan.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/bios/fan.c @@ -25,7 +25,7 @@ #include <subdev/bios/bit.h> #include <subdev/bios/fan.h> -u16 +static u16 nvbios_fan_table(struct nvkm_bios *bios, u8 *ver, u8 *hdr, u8 *cnt, u8 *len) { struct bit_entry bit_P; @@ -52,7 +52,7 @@ nvbios_fan_table(struct nvkm_bios *bios, u8 *ver, u8 *hdr, u8 *cnt, u8 *len) return 0x0000; } -u16 +static u16 nvbios_fan_entry(struct nvkm_bios *bios, int idx, u8 *ver, u8 *hdr, u8 *cnt, u8 *len) { diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/clk/gt215.c b/drivers/gpu/drm/nouveau/nvkm/subdev/clk/gt215.c index 056702ef69aa..96e0941c8edd 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/clk/gt215.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/clk/gt215.c @@ -180,7 +180,7 @@ gt215_clk_read(struct nvkm_clk *base, enum nv_clk_src src) return 0; } -int +static int gt215_clk_info(struct nvkm_clk *base, int idx, u32 khz, struct gt215_clk_info *info) { diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ramgt215.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ramgt215.c index d15ea886df27..f10664372161 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ramgt215.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ramgt215.c @@ -95,7 +95,7 @@ struct gt215_ram { struct gt215_ltrain ltrain; }; -void +static void gt215_link_train_calc(u32 *vals, struct gt215_ltrain *train) { int i, lo, hi; @@ -149,7 +149,7 @@ gt215_link_train_calc(u32 *vals, struct gt215_ltrain *train) /* * Link training for (at least) DDR3 */ -int +static int gt215_link_train(struct gt215_ram *ram) { struct gt215_ltrain *train = &ram->ltrain; @@ -267,7 +267,7 @@ out: return ret; } -int +static int gt215_link_train_init(struct gt215_ram *ram) { static const u32 pattern[16] = { @@ -333,7 +333,7 @@ gt215_link_train_init(struct gt215_ram *ram) return 0; } -void +static void gt215_link_train_fini(struct gt215_ram *ram) { if (ram->ltrain.mem) diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/sddr2.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/sddr2.c index b9f1ffdfc602..4dcd8742f2da 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/sddr2.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/sddr2.c @@ -23,6 +23,7 @@ * Ben Skeggs */ #include "priv.h" +#include "ram.h" struct ramxlat { int id; diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/sddr3.c b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/sddr3.c index 26900333b1d6..eca8a445eab3 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/fb/sddr3.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/fb/sddr3.c @@ -23,6 +23,7 @@ * Roy Spliet <rspliet@xxxxxxxxxx> */ #include "priv.h" +#include "ram.h" struct ramxlat { int id; diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/gpio/gk104.c b/drivers/gpu/drm/nouveau/nvkm/subdev/gpio/gk104.c index 3f45afd17d5a..2ead515b8530 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/gpio/gk104.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/gpio/gk104.c @@ -37,7 +37,7 @@ gk104_gpio_intr_stat(struct nvkm_gpio *gpio, u32 *hi, u32 *lo) nvkm_wr32(device, 0x00dc80, intr1); } -void +static void gk104_gpio_intr_mask(struct nvkm_gpio *gpio, u32 type, u32 mask, u32 data) { struct nvkm_device *device = gpio->subdev.device; diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/i2c/aux.c b/drivers/gpu/drm/nouveau/nvkm/subdev/i2c/aux.c index f0851d57df2f..01d5c5a56e2e 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/i2c/aux.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/i2c/aux.c @@ -74,7 +74,7 @@ nvkm_i2c_aux_i2c_func(struct i2c_adapter *adap) return I2C_FUNC_I2C | I2C_FUNC_SMBUS_EMUL; } -const struct i2c_algorithm +static const struct i2c_algorithm nvkm_i2c_aux_i2c_algo = { .master_xfer = nvkm_i2c_aux_i2c_xfer, .functionality = nvkm_i2c_aux_i2c_func diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/iccsense/base.c b/drivers/gpu/drm/nouveau/nvkm/subdev/iccsense/base.c index 41bd5d0f7692..6c49beec5bde 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/iccsense/base.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/iccsense/base.c @@ -329,7 +329,7 @@ nvkm_iccsense_init(struct nvkm_subdev *subdev) return 0; } -struct nvkm_subdev_func iccsense_func = { +static const struct nvkm_subdev_func iccsense_func = { .oneinit = nvkm_iccsense_oneinit, .init = nvkm_iccsense_init, .dtor = nvkm_iccsense_dtor, diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/instmem/base.c b/drivers/gpu/drm/nouveau/nvkm/subdev/instmem/base.c index 8ed8f65ff664..10c987a654ec 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/instmem/base.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/instmem/base.c @@ -104,7 +104,7 @@ nvkm_instobj_dtor(struct nvkm_memory *memory) return iobj; } -const struct nvkm_memory_func +static const struct nvkm_memory_func nvkm_instobj_func = { .dtor = nvkm_instobj_dtor, .target = nvkm_instobj_target, @@ -156,7 +156,7 @@ nvkm_instobj_wr32_slow(struct nvkm_memory *memory, u64 offset, u32 data) return nvkm_wo32(iobj->parent, offset, data); } -const struct nvkm_memory_func +static const struct nvkm_memory_func nvkm_instobj_func_slow = { .dtor = nvkm_instobj_dtor, .target = nvkm_instobj_target, diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/mc/g84.c b/drivers/gpu/drm/nouveau/nvkm/subdev/mc/g84.c index c3d66ef5dc12..430a61c3df44 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/mc/g84.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/mc/g84.c @@ -34,7 +34,7 @@ g84_mc_reset[] = { {} }; -const struct nvkm_mc_map +static const struct nvkm_mc_map g84_mc_intr[] = { { 0x04000000, NVKM_ENGINE_DISP }, { 0x00020000, NVKM_ENGINE_VP }, diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/secboot/gm200.c b/drivers/gpu/drm/nouveau/nvkm/subdev/secboot/gm200.c index f1e2dc914366..ec48e4ace37a 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/secboot/gm200.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/secboot/gm200.c @@ -1364,7 +1364,7 @@ gm200_secboot_init(struct nvkm_secboot *sb) return 0; } -int +static int gm200_secboot_fini(struct nvkm_secboot *sb, bool suspend) { struct gm200_secboot *gsb = gm200_secboot(sb); diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/volt/gk104.c b/drivers/gpu/drm/nouveau/nvkm/subdev/volt/gk104.c index 420bd84d8483..1527d12aa222 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/volt/gk104.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/volt/gk104.c @@ -34,7 +34,7 @@ struct gk104_volt { struct nvbios_volt bios; }; -int +static int gk104_volt_get(struct nvkm_volt *base) { struct nvbios_volt *bios = &gk104_volt(base)->bios; @@ -47,7 +47,7 @@ gk104_volt_get(struct nvkm_volt *base) return bios->base + bios->pwm_range * duty / div; } -int +static int gk104_volt_set(struct nvkm_volt *base, u32 uv) { struct nvbios_volt *bios = &gk104_volt(base)->bios; diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/volt/gm20b.c b/drivers/gpu/drm/nouveau/nvkm/subdev/volt/gm20b.c index 74db4d28930f..2925b9cae681 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/volt/gm20b.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/volt/gm20b.c @@ -25,7 +25,7 @@ #include <core/tegra.h> -const struct cvb_coef gm20b_cvb_coef[] = { +static const struct cvb_coef gm20b_cvb_coef[] = { /* KHz, c0, c1, c2 */ /* 76800 */ { 1786666, -85625, 1632 }, /* 153600 */ { 1846729, -87525, 1632 }, @@ -58,7 +58,7 @@ static const struct cvb_coef gm20b_na_cvb_coef[] = { /* 998400 */ { 1316991, 8144, -940, 808, -21583, 226 }, }; -const u32 speedo_to_vmin[] = { +static const u32 speedo_to_vmin[] = { /* 0, 1, 2, 3, 4, */ 950000, 840000, 818750, 840000, 810000, }; diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/volt/gpio.c b/drivers/gpu/drm/nouveau/nvkm/subdev/volt/gpio.c index d2bac1d77819..cb749a0ba582 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/volt/gpio.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/volt/gpio.c @@ -22,6 +22,7 @@ * Authors: Ben Skeggs */ #include <subdev/volt.h> +#include <subdev/volt/priv.h> #include <subdev/bios.h> #include <subdev/bios/gpio.h> #include <subdev/gpio.h> -- 2.7.4 _______________________________________________ dri-devel mailing list dri-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/dri-devel