forked from Xilinx/SLASH
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathslash_hotplug_driver.h
More file actions
46 lines (41 loc) · 1.61 KB
/
Copy pathslash_hotplug_driver.h
File metadata and controls
46 lines (41 loc) · 1.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/**
* Copyright (C) 2025 Advanced Micro Devices, Inc. All rights reserved.
* This program is free software; you can redistribute it and/or modify it under the terms of the
* GNU General Public License as published by the Free Software Foundation; version 2.
*
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without
* even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License along with this program; if
* not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301, USA.
*/
/**
* @file slash_hotplug_driver.h
*
* Kernel-internal interface for the SLASH hotplug subsystem.
*
* The hotplug subsystem manages the PCIe-level lifecycle of SLASH FPGA
* devices: removing them from the bus, performing Secondary Bus Resets,
* and rescanning. This is essential for FPGA reconfiguration workflows
* where loading a new bitstream requires re-enumerating the device.
*
* A single misc device (/dev/slash_hotplug) handles ioctls. All
* operations that target a specific device require an explicit BDF.
*/
#ifndef SLASH_HOTPLUG_DRIVER_H
#define SLASH_HOTPLUG_DRIVER_H
/**
* slash_hotplug_init() - Register the hotplug misc device.
*
* Creates /dev/slash_hotplug.
*
* Return: 0 on success, negative errno on failure.
*/
int slash_hotplug_init(void);
/**
* slash_hotplug_exit() - Unregister the hotplug misc device.
*/
void slash_hotplug_exit(void);
#endif /* SLASH_HOTPLUG_DRIVER_H */