The branch main has been updated by dumbbell (ports committer):

URL: 
https://cgit.FreeBSD.org/src/commit/?id=b9ef0689433d7d08c96695e571c4c262a3ac9007

commit b9ef0689433d7d08c96695e571c4c262a3ac9007
Author:     Jean-Sébastien Pédron <dumbb...@freebsd.org>
AuthorDate: 2023-01-22 13:46:54 +0000
Commit:     Jean-Sébastien Pédron <dumbb...@freebsd.org>
CommitDate: 2023-01-30 22:10:03 +0000

    linuxkpi: Define `dev_is_platform()` and `to_platform_device()`
    
    The former returns false and the latter returns NULL.
    
    Reviewed by:    manu
    Approved by:    manu
    Differential Revision:  https://reviews.freebsd.org/D38163
---
 sys/compat/linuxkpi/common/include/linux/platform_device.h | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/sys/compat/linuxkpi/common/include/linux/platform_device.h 
b/sys/compat/linuxkpi/common/include/linux/platform_device.h
index f07b5aac967b..f45cdce829c4 100644
--- a/sys/compat/linuxkpi/common/include/linux/platform_device.h
+++ b/sys/compat/linuxkpi/common/include/linux/platform_device.h
@@ -42,6 +42,8 @@ struct platform_driver {
        struct device_driver            driver;
 };
 
+#define        dev_is_platform(dev)    (false)
+#define        to_platform_device(dev) (NULL)
 
 static __inline int
 platform_driver_register(struct platform_driver *pdrv)
@@ -76,4 +78,12 @@ platform_driver_unregister(struct platform_driver *pdrv)
        return;
 }
 
+static __inline void
+platform_device_unregister(struct platform_device *pdev)
+{
+
+       pr_debug("%s: TODO\n", __func__);
+       return;
+}
+
 #endif /* _LINUXKPI_LINUX_PLATFORM_DEVICE_H */

Reply via email to