Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/external/bsd/drm2/pci New stub to reduce diff.



details:   https://anonhg.NetBSD.org/src/rev/6c1b6484a9a0
branches:  trunk
changeset: 969273:6c1b6484a9a0
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Fri Feb 14 04:29:19 2020 +0000

description:
New stub to reduce diff.

diffstat:

 sys/external/bsd/drm2/dist/drm/amd/amdgpu/amdgpu_ci_dpm.c |   8 ++------
 sys/external/bsd/drm2/dist/drm/radeon/radeon_ci_dpm.c     |   8 ++------
 sys/external/bsd/drm2/dist/drm/radeon/radeon_si_dpm.c     |   8 ++------
 sys/external/bsd/drm2/pci/drm_pci.c                       |  11 +++++++++--
 4 files changed, 15 insertions(+), 20 deletions(-)

diffs (153 lines):

diff -r c42efa01af7c -r 6c1b6484a9a0 sys/external/bsd/drm2/dist/drm/amd/amdgpu/amdgpu_ci_dpm.c
--- a/sys/external/bsd/drm2/dist/drm/amd/amdgpu/amdgpu_ci_dpm.c Fri Feb 14 04:20:59 2020 +0000
+++ b/sys/external/bsd/drm2/dist/drm/amd/amdgpu/amdgpu_ci_dpm.c Fri Feb 14 04:29:19 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: amdgpu_ci_dpm.c,v 1.2 2018/08/27 14:24:03 riastradh Exp $      */
+/*     $NetBSD: amdgpu_ci_dpm.c,v 1.3 2020/02/14 04:29:19 riastradh Exp $      */
 
 /*
  * Copyright 2013 Advanced Micro Devices, Inc.
@@ -24,7 +24,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: amdgpu_ci_dpm.c,v 1.2 2018/08/27 14:24:03 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: amdgpu_ci_dpm.c,v 1.3 2020/02/14 04:29:19 riastradh Exp $");
 
 #include <linux/firmware.h>
 #include <linux/module.h>
@@ -5858,22 +5858,18 @@
        u8 frev, crev;
        struct ci_power_info *pi;
        int ret;
-#ifndef __NetBSD__             /* XXX amdgpu pcie */
        u32 mask;
-#endif
 
        pi = kzalloc(sizeof(struct ci_power_info), GFP_KERNEL);
        if (pi == NULL)
                return -ENOMEM;
        adev->pm.dpm.priv = pi;
 
-#ifndef __NetBSD__             /* XXX amdgpu pcie */
        ret = drm_pcie_get_speed_cap_mask(adev->ddev, &mask);
        if (ret)
                pi->sys_pcie_mask = 0;
        else
                pi->sys_pcie_mask = mask;
-#endif
        pi->force_pcie_gen = AMDGPU_PCIE_GEN_INVALID;
 
        pi->pcie_gen_performance.max = AMDGPU_PCIE_GEN1;
diff -r c42efa01af7c -r 6c1b6484a9a0 sys/external/bsd/drm2/dist/drm/radeon/radeon_ci_dpm.c
--- a/sys/external/bsd/drm2/dist/drm/radeon/radeon_ci_dpm.c     Fri Feb 14 04:20:59 2020 +0000
+++ b/sys/external/bsd/drm2/dist/drm/radeon/radeon_ci_dpm.c     Fri Feb 14 04:29:19 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: radeon_ci_dpm.c,v 1.1 2018/08/27 14:38:20 riastradh Exp $      */
+/*     $NetBSD: radeon_ci_dpm.c,v 1.2 2020/02/14 04:29:19 riastradh Exp $      */
 
 /*
  * Copyright 2013 Advanced Micro Devices, Inc.
@@ -24,7 +24,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: radeon_ci_dpm.c,v 1.1 2018/08/27 14:38:20 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: radeon_ci_dpm.c,v 1.2 2020/02/14 04:29:19 riastradh Exp $");
 
 #include <linux/firmware.h>
 #include "drmP.h"
@@ -5664,22 +5664,18 @@
        u8 frev, crev;
        struct ci_power_info *pi;
        int ret;
-#ifndef __NetBSD__
        u32 mask;
-#endif
 
        pi = kzalloc(sizeof(struct ci_power_info), GFP_KERNEL);
        if (pi == NULL)
                return -ENOMEM;
        rdev->pm.dpm.priv = pi;
 
-#ifndef __NetBSD__
        ret = drm_pcie_get_speed_cap_mask(rdev->ddev, &mask);
        if (ret)
                pi->sys_pcie_mask = 0;
        else
                pi->sys_pcie_mask = mask;
-#endif
        pi->force_pcie_gen = RADEON_PCIE_GEN_INVALID;
 
        pi->pcie_gen_performance.max = RADEON_PCIE_GEN1;
diff -r c42efa01af7c -r 6c1b6484a9a0 sys/external/bsd/drm2/dist/drm/radeon/radeon_si_dpm.c
--- a/sys/external/bsd/drm2/dist/drm/radeon/radeon_si_dpm.c     Fri Feb 14 04:20:59 2020 +0000
+++ b/sys/external/bsd/drm2/dist/drm/radeon/radeon_si_dpm.c     Fri Feb 14 04:29:19 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: radeon_si_dpm.c,v 1.1 2018/08/27 14:38:20 riastradh Exp $      */
+/*     $NetBSD: radeon_si_dpm.c,v 1.2 2020/02/14 04:29:19 riastradh Exp $      */
 
 /*
  * Copyright 2013 Advanced Micro Devices, Inc.
@@ -24,7 +24,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: radeon_si_dpm.c,v 1.1 2018/08/27 14:38:20 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: radeon_si_dpm.c,v 1.2 2020/02/14 04:29:19 riastradh Exp $");
 
 #include "drmP.h"
 #include "radeon.h"
@@ -6957,9 +6957,7 @@
        struct si_power_info *si_pi;
        struct atom_clock_dividers dividers;
        int ret;
-#ifndef __NetBSD__             /* XXX radeon pcie */
        u32 mask;
-#endif
 
        si_pi = kzalloc(sizeof(struct si_power_info), GFP_KERNEL);
        if (si_pi == NULL)
@@ -6969,13 +6967,11 @@
        eg_pi = &ni_pi->eg;
        pi = &eg_pi->rv7xx;
 
-#ifndef __NetBSD__             /* XXX radeon pcie */
        ret = drm_pcie_get_speed_cap_mask(rdev->ddev, &mask);
        if (ret)
                si_pi->sys_pcie_mask = 0;
        else
                si_pi->sys_pcie_mask = mask;
-#endif
        si_pi->force_pcie_gen = RADEON_PCIE_GEN_INVALID;
        si_pi->boot_pcie_gen = si_get_current_pcie_speed(rdev);
 
diff -r c42efa01af7c -r 6c1b6484a9a0 sys/external/bsd/drm2/pci/drm_pci.c
--- a/sys/external/bsd/drm2/pci/drm_pci.c       Fri Feb 14 04:20:59 2020 +0000
+++ b/sys/external/bsd/drm2/pci/drm_pci.c       Fri Feb 14 04:29:19 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: drm_pci.c,v 1.32 2018/11/15 06:53:58 riastradh Exp $   */
+/*     $NetBSD: drm_pci.c,v 1.33 2020/02/14 04:29:19 riastradh Exp $   */
 
 /*-
  * Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: drm_pci.c,v 1.32 2018/11/15 06:53:58 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: drm_pci.c,v 1.33 2020/02/14 04:29:19 riastradh Exp $");
 
 #include <sys/types.h>
 #include <sys/errno.h>
@@ -300,3 +300,10 @@
        /* Success!  */
        return 0;
 }
+
+int
+drm_pcie_get_speed_cap_mask(struct drm_device *dev, u32 *speed_mask)
+{
+
+       return -ENOSYS;
+}



Home | Main Index | Thread Index | Old Index