mirror of
https://github.com/lemonade-sdk/mac_linuxgpu.git
synced 2026-11-22 23:57:31 -10:00
Runs the unmodified upstream Linux amdgpu and amdkfd drivers on Apple Silicon Macs inside a DriverKit system extension, for AMD GPUs attached over Thunderbolt. The Linux sources come from a pinned submodule and are compiled against linuxu, a userspace implementation of the Linux kernel APIs they use. Includes the HSA runtime, the host installer app, the setup and firmware fetch scripts, and the offline test suite.
23 lines
917 B
C
23 lines
917 B
C
/* linuxu: SHIM (third_party/linux/include/linux/chardev.h)
|
|
* Character-device registration surface. The compute dext registers the KFD
|
|
* device via an OS-layer path (P2); the registration calls are declared here
|
|
* and resolved at link time. */
|
|
#ifndef _LINUX_CHARDEV_H
|
|
#define _LINUX_CHARDEV_H
|
|
|
|
#include <linux/types.h>
|
|
#include <linux/kdev_t.h>
|
|
|
|
struct file_operations;
|
|
|
|
extern int register_chrdev(unsigned int major, const char *name,
|
|
const struct file_operations *fops);
|
|
extern void unregister_chrdev(unsigned int major, const char *name);
|
|
extern int register_chrdev_region(dev_t from, unsigned count, const char *name);
|
|
extern void unregister_chrdev_region(dev_t from, unsigned count);
|
|
extern int alloc_chrdev_region(dev_t *dev, unsigned int baseminor,
|
|
unsigned int count, const char *name);
|
|
extern void unregister_chrdev_region(dev_t from, unsigned int count);
|
|
|
|
#endif /* _LINUX_CHARDEV_H */
|