Displaying 20 results from an estimated 33 matches for "pci_get_bus_and_slot".
2017 Nov 27
1
[PATCH V3 10/29] drm/nouveau: deprecate pci_get_bus_and_slot()
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Getting ready to remove pci_get_bus_and_slot() function in favor of
pci_get_domain_bus_and_slot().
Replace pci_get_bus_and_slot() with pci_get_...
2017 Dec 19
1
[PATCH V4 09/26] drm/nouveau: deprecate pci_get_bus_and_slot()
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Getting ready to remove pci_get_bus_and_slot() function in favor of
pci_get_domain_bus_and_slot().
Replace pci_get_bus_and_slot() with pci_get_...
2017 Nov 22
0
[PATCH V2 10/29] drm/nouveau: deprecate pci_get_bus_and_slot()
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Getting ready to remove pci_get_bus_and_slot() function in favor of
pci_get_domain_bus_and_slot().
Replace pci_get_bus_and_slot() with pci_get_...
2017 Nov 27
0
[PATCH V3 10/29] drm/nouveau: deprecate pci_get_bus_and_slot()
+nouveau at lists.freedesktop.org
On 11/27/2017 11:57 AM, Sinan Kaya wrote:
> pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
> where a PCI device is present. This restricts the device drivers to be
> reused for other domain numbers.
>
> Getting ready to remove pci_get_bus_and_slot() function in favor of
> pci_get_domain_bus_and_slot().
>
> Replace p...
2017 Nov 22
0
[PATCH 10/30] drm/nouveau: deprecate pci_get_bus_and_slot()
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the actual domain nu...
2007 Aug 18
1
[Bug 12051] New: inserting nouveau.ko failed with kernel 2.6.17 since commit 8a4d7f34d9c0182c466518c6f413d9a039db402d
...top.org
ReportedBy: mjulien.m at gmail.com
QAContact: xorg-team at lists.x.org
Hi,
Since commit 8a4d7f34d9c0182c466518c6f413d9a039db402d, when I try to insert
nouveau.ko, it failed with unknown symbol, and dmesg say :
[drm] Initialized drm 1.1.0 20060810
nouveau: Unknown symbol pci_get_bus_and_slot
I get a warning at this place during the compilation
/home/jules/nouveau/drm/linux-core/nouveau_mem.o
/home/jules/nouveau/drm/linux-core/nouveau_mem.c: In function
'nouveau_mem_fb_amount_igp':
/home/jules/nouveau/drm/linux-core/nouveau_mem.c:230: warning: implicit
declaration of function...
2017 Jan 20
0
[PATCH] nv1a,nv1f/disp: fix memory clock rate retrieval
...ff --git a/drm/nouveau/dispnv04/hw.c b/drm/nouveau/dispnv04/hw.c
index 48ad4be..b985990 100644
--- a/drm/nouveau/dispnv04/hw.c
+++ b/drm/nouveau/dispnv04/hw.c
@@ -222,6 +222,7 @@ nouveau_hw_get_clock(struct drm_device *dev, enum nvbios_pll_type plltype)
uint32_t mpllP;
pci_read_config_dword(pci_get_bus_and_slot(0, 3), 0x6c, &mpllP);
+ mpllP = (mpllP >> 8) & 0xf;
if (!mpllP)
mpllP = 4;
@@ -232,7 +233,7 @@ nouveau_hw_get_clock(struct drm_device *dev, enum nvbios_pll_type plltype)
uint32_t clock;
pci_read_config_dword(pci_get_bus_and_slot(0, 5), 0x4c, &clock);
- return cl...
2013 Jul 24
4
[PATCH] [RFC] drm/nouveau: bring back hdmi audio device after switcheroo power down
...dev *pdev,
return 0;
}
+#define PCI_CLASS_MULTIMEDIA_HD_AUDIO 0x0403
+
+static void
+nouveau_get_hdmi_dev(struct drm_device *dev)
+{
+ struct nouveau_drm *drm = dev->dev_private;
+ struct pci_dev *pdev = dev->pdev;
+
+ /* subfunction one is a hdmi audio device? */
+ drm->hdmi_device = pci_get_bus_and_slot((unsigned int)pdev->bus->number,
+ PCI_DEVFN(PCI_SLOT(pdev->devfn), 1));
+
+ if (!drm->hdmi_device) {
+ DRM_INFO("hdmi device not found %d %d %d\n", pdev->bus->number, PCI_SLOT(pdev->devfn), 1);
+ return;
+ }
+
+ if ((drm->hdmi_device->class >> 8)...
2008 Aug 12
0
SR-IOV: patches are available for Linux kernel [3/4]
...ce);
+
+ pci_device_add(vf, pb);
+ pci_bus_add_devices(pb);
+
+ return vf;
+
+failed:
+ kfree(vf);
+ return NULL;
+}
+
+static int iov_add_virtfn(struct pci_dev *pf, int vfid, char *param)
+{
+ int err;
+ struct pci_dev *vf;
+ u8 bus, devfn;
+
+ vfid_to_bdf(pf, vfid, &bus, &devfn);
+
+ vf = pci_get_bus_and_slot(bus, devfn);
+ if (vf) {
+ strcpy(pf->iov->args[vfid], param);
+ return notify_phyfn(pf, PCI_IOV_VF_PAR, vfid);
+ }
+
+ pf->iov->args[vfid] = kmalloc(VF_PARAM_LEN, GFP_KERNEL);
+ if (!pf->iov->args[vfid])
+ return -ENOMEM;
+
+ strcpy(pf->iov->args[vfid], param);
+ err = n...
2008 Aug 12
0
SR-IOV: patches are available for Linux kernel [3/4]
...ce);
+
+ pci_device_add(vf, pb);
+ pci_bus_add_devices(pb);
+
+ return vf;
+
+failed:
+ kfree(vf);
+ return NULL;
+}
+
+static int iov_add_virtfn(struct pci_dev *pf, int vfid, char *param)
+{
+ int err;
+ struct pci_dev *vf;
+ u8 bus, devfn;
+
+ vfid_to_bdf(pf, vfid, &bus, &devfn);
+
+ vf = pci_get_bus_and_slot(bus, devfn);
+ if (vf) {
+ strcpy(pf->iov->args[vfid], param);
+ return notify_phyfn(pf, PCI_IOV_VF_PAR, vfid);
+ }
+
+ pf->iov->args[vfid] = kmalloc(VF_PARAM_LEN, GFP_KERNEL);
+ if (!pf->iov->args[vfid])
+ return -ENOMEM;
+
+ strcpy(pf->iov->args[vfid], param);
+ err = n...
2008 Aug 12
0
SR-IOV: patches are available for Linux kernel [3/4]
...ce);
+
+ pci_device_add(vf, pb);
+ pci_bus_add_devices(pb);
+
+ return vf;
+
+failed:
+ kfree(vf);
+ return NULL;
+}
+
+static int iov_add_virtfn(struct pci_dev *pf, int vfid, char *param)
+{
+ int err;
+ struct pci_dev *vf;
+ u8 bus, devfn;
+
+ vfid_to_bdf(pf, vfid, &bus, &devfn);
+
+ vf = pci_get_bus_and_slot(bus, devfn);
+ if (vf) {
+ strcpy(pf->iov->args[vfid], param);
+ return notify_phyfn(pf, PCI_IOV_VF_PAR, vfid);
+ }
+
+ pf->iov->args[vfid] = kmalloc(VF_PARAM_LEN, GFP_KERNEL);
+ if (!pf->iov->args[vfid])
+ return -ENOMEM;
+
+ strcpy(pf->iov->args[vfid], param);
+ err = n...
2008 Sep 01
2
[PATCH 3/4 v2] PCI: support SR-IOV capability
...return pci_bus_add_device(new);
+}
+
+static int enable_virtfn(struct hotplug_slot *slot)
+{
+ int rc;
+ u8 busnr, devfn;
+ struct pci_dev *dev;
+ struct virtfn_slot *vslot = slot->private;
+
+ get_addr(vslot->dev, vslot->id, &busnr, &devfn);
+
+ mutex_lock(&iov_lock);
+ dev = pci_get_bus_and_slot(busnr, devfn);
+ if (dev) {
+ pci_dev_put(dev);
+ rc = -EINVAL;
+ goto out;
+ }
+
+ rc = notify(vslot->dev, PCI_IOV_VF_ENABLE,
+ vslot->id, vslot->slot->info->param);
+ if (rc)
+ goto out;
+
+ rc = alloc_virtfn(vslot->dev, vslot->id);
+ if (!rc)
+ slot->info->p...
2008 Sep 01
2
[PATCH 3/4 v2] PCI: support SR-IOV capability
...return pci_bus_add_device(new);
+}
+
+static int enable_virtfn(struct hotplug_slot *slot)
+{
+ int rc;
+ u8 busnr, devfn;
+ struct pci_dev *dev;
+ struct virtfn_slot *vslot = slot->private;
+
+ get_addr(vslot->dev, vslot->id, &busnr, &devfn);
+
+ mutex_lock(&iov_lock);
+ dev = pci_get_bus_and_slot(busnr, devfn);
+ if (dev) {
+ pci_dev_put(dev);
+ rc = -EINVAL;
+ goto out;
+ }
+
+ rc = notify(vslot->dev, PCI_IOV_VF_ENABLE,
+ vslot->id, vslot->slot->info->param);
+ if (rc)
+ goto out;
+
+ rc = alloc_virtfn(vslot->dev, vslot->id);
+ if (!rc)
+ slot->info->p...
2008 Sep 01
2
[PATCH 3/4 v2] PCI: support SR-IOV capability
...return pci_bus_add_device(new);
+}
+
+static int enable_virtfn(struct hotplug_slot *slot)
+{
+ int rc;
+ u8 busnr, devfn;
+ struct pci_dev *dev;
+ struct virtfn_slot *vslot = slot->private;
+
+ get_addr(vslot->dev, vslot->id, &busnr, &devfn);
+
+ mutex_lock(&iov_lock);
+ dev = pci_get_bus_and_slot(busnr, devfn);
+ if (dev) {
+ pci_dev_put(dev);
+ rc = -EINVAL;
+ goto out;
+ }
+
+ rc = notify(vslot->dev, PCI_IOV_VF_ENABLE,
+ vslot->id, vslot->slot->info->param);
+ if (rc)
+ goto out;
+
+ rc = alloc_virtfn(vslot->dev, vslot->id);
+ if (!rc)
+ slot->info->p...
2014 Feb 13
1
[PATCH 1/2] drm/nouveau: make hdmi device finding failure prints debug level
...eau_get_hdmi_dev(struct drm_device *dev)
+nouveau_get_hdmi_dev(struct nouveau_drm *drm)
{
- struct nouveau_drm *drm = dev->dev_private;
- struct pci_dev *pdev = dev->pdev;
+ struct pci_dev *pdev = drm->dev->pdev;
/* subfunction one is a hdmi audio device? */
drm->hdmi_device = pci_get_bus_and_slot((unsigned int)pdev->bus->number,
PCI_DEVFN(PCI_SLOT(pdev->devfn), 1));
if (!drm->hdmi_device) {
- DRM_INFO("hdmi device not found %d %d %d\n", pdev->bus->number, PCI_SLOT(pdev->devfn), 1);
+ nv_debug(drm, "hdmi device not found %d %d %d\n", pde...
2013 Jul 24
0
[PATCH] [RFC] drm/nouveau: bring back hdmi audio device after switcheroo power down
...S_MULTIMEDIA_HD_AUDIO 0x0403
> +
> +static void
> +nouveau_get_hdmi_dev(struct drm_device *dev)
> +{
> + struct nouveau_drm *drm = dev->dev_private;
> + struct pci_dev *pdev = dev->pdev;
> +
> + /* subfunction one is a hdmi audio device? */
> + drm->hdmi_device = pci_get_bus_and_slot((unsigned int)pdev->bus->number,
> + PCI_DEVFN(PCI_SLOT(pdev->devfn), 1));
> +
> + if (!drm->hdmi_device) {
> + DRM_INFO("hdmi device not found %d %d %d\n", pdev->bus->number, PCI_SLOT(pdev->devfn), 1);
> + return;
> + }
> +
> + if ((dr...
2009 Nov 23
2
[PATCH 1/3] drm/nouveau: Update the CRTC arbitration parameters on FB depth switch.
Signed-off-by: Francisco Jerez <currojerez at riseup.net>
---
drivers/gpu/drm/nouveau/nv04_crtc.c | 37 +++++++++++++++++++++-------------
1 files changed, 23 insertions(+), 14 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nv04_crtc.c b/drivers/gpu/drm/nouveau/nv04_crtc.c
index 2ab9f30..0a5cfc1 100644
--- a/drivers/gpu/drm/nouveau/nv04_crtc.c
+++ b/drivers/gpu/drm/nouveau/nv04_crtc.c
2008 Sep 27
3
[PATCH 4/6 v3] PCI: support SR-IOV capability
...STEM_ID, &new->subsystem_device);
+
+ pci_device_add(new, bus);
+ return pci_bus_add_device(new);
+}
+
+static void vf_remove(struct pci_dev *dev, int vfn)
+{
+ u8 busnr, devfn;
+ struct pci_dev *tmp;
+
+ vf_rid(dev, vfn, &busnr, &devfn);
+
+ tmp = pci_get_bus_and_slot(busnr, devfn);
+ if (!tmp)
+ return;
+
+ pci_dev_put(tmp);
+ pci_remove_bus_device(tmp);
+}
+
+static int iov_enable(struct pci_iov *iov)
+{
+ int rc;
+ int i, j;
+ u16 ctrl;
+
+ if (!iov->notify)
+ return -ENODEV;
+
+ i...
2008 Sep 27
3
[PATCH 4/6 v3] PCI: support SR-IOV capability
...STEM_ID, &new->subsystem_device);
+
+ pci_device_add(new, bus);
+ return pci_bus_add_device(new);
+}
+
+static void vf_remove(struct pci_dev *dev, int vfn)
+{
+ u8 busnr, devfn;
+ struct pci_dev *tmp;
+
+ vf_rid(dev, vfn, &busnr, &devfn);
+
+ tmp = pci_get_bus_and_slot(busnr, devfn);
+ if (!tmp)
+ return;
+
+ pci_dev_put(tmp);
+ pci_remove_bus_device(tmp);
+}
+
+static int iov_enable(struct pci_iov *iov)
+{
+ int rc;
+ int i, j;
+ u16 ctrl;
+
+ if (!iov->notify)
+ return -ENODEV;
+
+ i...
2014 Feb 12
0
[PATCH v2] drm/nouveau: support for platform devices
...truct drm_device *dev)
struct nouveau_drm *drm = dev->dev_private;
struct pci_dev *pdev = dev->pdev;
+ if (!pdev) {
+ DRM_INFO("not a PCI device; no HDMI");
+ drm->hdmi_device = NULL;
+ return;
+ }
+
/* subfunction one is a hdmi audio device? */
drm->hdmi_device = pci_get_bus_and_slot((unsigned int)pdev->bus->number,
PCI_DEVFN(PCI_SLOT(pdev->devfn), 1));
@@ -330,7 +352,8 @@ nouveau_drm_load(struct drm_device *dev, unsigned long flags)
struct nouveau_drm *drm;
int ret;
- ret = nouveau_cli_create(pdev, "DRM", sizeof(*drm), (void**)&drm);
+ ret =...