/* * linux/drivers/video/nvidia/nv_of.c * * Copyright 2004 Antonino A. Daplas * * Based on rivafb-i2c.c * * This file is subject to the terms and conditions of the GNU General Public * License. See the file COPYING in the main directory of this archive * for more details. */ #include #include #include #include #include #include #include #include "nv_type.h" #include "nv_local.h" #include "nv_proto.h" #include "../edid.h" int nvidia_probe_of_connector(struct fb_info *info, int conn, u8 **out_edid) { struct nvidia_par *par = info->par; struct device_node *parent, *dp; const unsigned char *pedid = NULL; static char *propnames[] = { "DFP,EDID", "LCD,EDID", "EDID", "EDID1", "EDID,B", "EDID,A", NULL }; int i; parent = pci_device_to_OF_node(par->pci_dev); if (parent == NULL) return -1; if (par->twoHeads) { const char *pname; int len; for (dp = NULL; (dp = of_get_next_child(parent, dp)) != NULL;) { pname = of_get_property(dp, "name", NULL); if (!pname) continue; len = strlen(pname); if ((pname[len-1] == 'A' && conn == 1) || (pname[len-1] == 'B' && conn == 2)) { for (i = 0; propnames[i] != NULL; ++i) { pedid = of_get_property(dp, propnames[i], NULL); if (pedid != NULL) break; } of_node_put(dp); break; } } } if (pedid == NULL) { for (i = 0; propnames[i] != NULL; ++i) { pedid = of_get_property(parent, propnames[i], NULL); if (pedid != NULL) break; } } if (pedid) { *out_edid = kmemdup(pedid, EDID_LENGTH, GFP_KERNEL); if (*out_edid == NULL) return -1; printk(KERN_DEBUG "nvidiafb: Found OF EDID for head %d\n", conn); return 0; } return -1; } ock.c?h=nds-private-remove'>logtreecommitdiff
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2017-01-30 22:05:52 -0500
committerDavid S. Miller <davem@davemloft.net>2017-01-30 22:05:52 -0500
commit1bae6c99decf9137069646b593d3439171a8a8e2 (patch)
tree431604a568cd2303973470de326bd9731370a025 /net/sunrpc/svcsock.c
parent63c190429020a9701b42887ac22c28f287f1762f (diff)
parent2b2d3eb41c920b47df2fcedd1489cf748bd09466 (diff)
Merge branch 'sh_eth-E-DMAC-interrupt-mask-cleanups'
Sergei Shtylyov says: ==================== sh_eth: E-DMAC interrupt mask cleanups Here's a set of 3 patches against DaveM's 'net-next.git' repo. The main goal of this set is to stop using the bare numbers for the E-DMAC interrupt masks. [1/3] sh_eth: rename EESIPR bits [2/3] sh_eth: add missing EESIPR bits [3/3] sh_eth: stop using bare numbers for EESIPR values ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sunrpc/svcsock.c')