mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-24 02:22:34 +03:00
gpu: nvgpu: mig: Defer dev_nodes creation and create new power node to support MIG
- This is deferring the dev_nodes creation after power_on to select the MIG config and to create the dev_nodes as per the selected MIG config. - The patch is adding a device node to issue power on. The nodes are: for igpu :/dev/nvgpu/igpu0/power for dgpu:/dev/nvgpu/dgpu-0001:01:00.0/power To issue power on : echo "1" > /dev/nvgpu/igpu0/power echo "1" > /dev/nvgpu/dgpu-0001:01:00.0/power JIRA NVGPU-6633 Change-Id: Ic4f1f3e42724cc788dcfaf0e881d188fd3bd1ce1 Signed-off-by: dt <dt@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2512647 Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2017, NVIDIA CORPORATION. All rights reserved.
|
||||
* Copyright (c) 2017-2021, NVIDIA CORPORATION. All rights reserved.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it
|
||||
* under the terms and conditions of the GNU General Public License,
|
||||
@@ -50,6 +50,7 @@ struct nvgpu_class {
|
||||
struct nvgpu_cdev_class_priv_data *priv_data;
|
||||
|
||||
enum nvgpu_mig_gpu_instance_type instance_type;
|
||||
bool power_node;
|
||||
};
|
||||
|
||||
static inline struct nvgpu_class *
|
||||
@@ -60,6 +61,7 @@ nvgpu_class_from_list_entry(struct nvgpu_list_node *node)
|
||||
};
|
||||
|
||||
int gk20a_user_init(struct device *dev);
|
||||
int gk20a_power_node_init(struct device *dev);
|
||||
void gk20a_user_deinit(struct device *dev);
|
||||
|
||||
struct gk20a *nvgpu_get_gk20a_from_cdev(struct nvgpu_cdev *cdev);
|
||||
|
||||
Reference in New Issue
Block a user