diff for duplicates of <20180828154433.5693-6-robh@kernel.org> diff --git a/a/1.txt b/N1/1.txt index b3ba82e..3a13246 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -113,7 +113,7 @@ index b51cbb9e87dc..17c87d29ff20 100644 @@ -201,7 +201,7 @@ char * __init build_path_component(struct device_node *dp) tmp_buf[0] = '\0'; __build_path_component(dp, tmp_buf); - if (tmp_buf[0] = '\0') + if (tmp_buf[0] == '\0') - strcpy(tmp_buf, dp->name); + snprintf(tmp_buf, sizeof(tmp_buf), "%pOFn", dp); @@ -135,7 +135,7 @@ index baeaeed64993..6220411ce8fc 100644 (unsigned int) (regs->phys_addr & 0xffffffffUL)); return; @@ -97,17 +97,17 @@ static void __init sun4v_path_component(struct device_node *dp, char *tmp_buf) - const char *prefix = (type = 0) ? "m" : "i"; + const char *prefix = (type == 0) ? "m" : "i"; if (low_bits) - sprintf(tmp_buf, "%s@%s%x,%x", @@ -150,7 +150,7 @@ index baeaeed64993..6220411ce8fc 100644 + dp, prefix, high_bits); - } else if (type = 12) { + } else if (type == 12) { - sprintf(tmp_buf, "%s@%x", - dp->name, high_bits); + sprintf(tmp_buf, "%pOFn@%x", @@ -254,7 +254,7 @@ index baeaeed64993..6220411ce8fc 100644 @@ -274,11 +274,11 @@ static void __init usb_path_component(struct device_node *dp, char *tmp_buf) regs = prop->value; - if (prop->length = sizeof(u32) || regs[1] = 1) { + if (prop->length == sizeof(u32) || regs[1] == 1) { - sprintf(tmp_buf, "%s@%x", - dp->name, regs[0]); + sprintf(tmp_buf, "%pOFn@%x", @@ -286,7 +286,7 @@ index baeaeed64993..6220411ce8fc 100644 @@ -361,7 +361,7 @@ char * __init build_path_component(struct device_node *dp) tmp_buf[0] = '\0'; __build_path_component(dp, tmp_buf); - if (tmp_buf[0] = '\0') + if (tmp_buf[0] == '\0') - strcpy(tmp_buf, dp->name); + snprintf(tmp_buf, sizeof(tmp_buf), "%pOFn", dp); diff --git a/a/content_digest b/N1/content_digest index 6e7b7d4..a36302e 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -1,7 +1,8 @@ "ref\020180828154433.5693-1-robh@kernel.org\0" + "ref\020180828015252.28511-7-robh@kernel.org\0" "From\0Rob Herring <robh@kernel.org>\0" "Subject\0[PATCH v2] sparc: Convert to using %pOFn instead of device_node.name\0" - "Date\0Tue, 28 Aug 2018 15:44:32 +0000\0" + "Date\0Tue, 28 Aug 2018 10:44:32 -0500\0" "To\0linux-kernel@vger.kernel.org\0" "Cc\0David S. Miller <davem@davemloft.net>" " sparclinux@vger.kernel.org\0" @@ -122,7 +123,7 @@ "@@ -201,7 +201,7 @@ char * __init build_path_component(struct device_node *dp)\n" " \ttmp_buf[0] = '\\0';\n" " \t__build_path_component(dp, tmp_buf);\n" - " \tif (tmp_buf[0] = '\\0')\n" + " \tif (tmp_buf[0] == '\\0')\n" "-\t\tstrcpy(tmp_buf, dp->name);\n" "+\t\tsnprintf(tmp_buf, sizeof(tmp_buf), \"%pOFn\", dp);\n" "\n" @@ -144,7 +145,7 @@ " \t\t\t(unsigned int) (regs->phys_addr & 0xffffffffUL));\n" " \t\treturn;\n" "@@ -97,17 +97,17 @@ static void __init sun4v_path_component(struct device_node *dp, char *tmp_buf)\n" - " \t\tconst char *prefix = (type = 0) ? \"m\" : \"i\";\n" + " \t\tconst char *prefix = (type == 0) ? \"m\" : \"i\";\n" "\n" " \t\tif (low_bits)\n" "-\t\t\tsprintf(tmp_buf, \"%s@%s%x,%x\",\n" @@ -159,7 +160,7 @@ "+\t\t\t\tdp,\n" " \t\t\t\tprefix,\n" " \t\t\t\thigh_bits);\n" - " \t} else if (type = 12) {\n" + " \t} else if (type == 12) {\n" "-\t\tsprintf(tmp_buf, \"%s@%x\",\n" "-\t\t\tdp->name, high_bits);\n" "+\t\tsprintf(tmp_buf, \"%pOFn@%x\",\n" @@ -263,7 +264,7 @@ "@@ -274,11 +274,11 @@ static void __init usb_path_component(struct device_node *dp, char *tmp_buf)\n" " \tregs = prop->value;\n" "\n" - " \tif (prop->length = sizeof(u32) || regs[1] = 1) {\n" + " \tif (prop->length == sizeof(u32) || regs[1] == 1) {\n" "-\t\tsprintf(tmp_buf, \"%s@%x\",\n" "-\t\t\tdp->name, regs[0]);\n" "+\t\tsprintf(tmp_buf, \"%pOFn@%x\",\n" @@ -295,7 +296,7 @@ "@@ -361,7 +361,7 @@ char * __init build_path_component(struct device_node *dp)\n" " \ttmp_buf[0] = '\\0';\n" " \t__build_path_component(dp, tmp_buf);\n" - " \tif (tmp_buf[0] = '\\0')\n" + " \tif (tmp_buf[0] == '\\0')\n" "-\t\tstrcpy(tmp_buf, dp->name);\n" "+\t\tsnprintf(tmp_buf, sizeof(tmp_buf), \"%pOFn\", dp);\n" "\n" @@ -304,4 +305,4 @@ "--\n" 2.17.1 -2393a8462ee3942f7f32f4913a19bef65de3c7bc180dc28973d3532ffacc4f48 +bc95c56f03b3a831d2e0e7f1e465ebd30d99273a670954c57a797b5c056be51c
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.