Thread (3 messages) 3 messages, 3 authors, 2006-11-16

Re: [PATCH 11/16] powerpc: add ps3 platform repository support

flat view

From: Michael Ellerman <hidden>
Date: 2006-11-16 00:12:54

On Wed, 2006-11-15 at 19:06 +0100, Christoph Hellwig wrote:
On Fri, Nov 10, 2006 at 12:03:08PM -0800, Geoff Levand wrote:
quoted
+ * make_first_field - Make the first field of a repository node name.
+ * @text: Text portion of the field.
+ * @index: Numeric index portion of the field.  Use zero for 'don't care'.
+ *
+ * This routine sets the vendor id to zero (non-vendor specific).
+ * Returns field value.
+ */
+
+static u64 make_first_field(const char *text, u64 index)
+{
+	u64 n;
+
+	strncpy((char *)&n, text, 8);
+	return ps3pf_vendor_id_none + (n >> 32) + index;
+}
a strncpy into a const pointer doesn't make any sense.
It's from a const pointer into a u64.

It still doesn't make any sense though .. crazy hypervisor weirdness.

cheers

-- 
Michael Ellerman
OzLabs, IBM Australia Development Lab

wwweb: http://michael.ellerman.id.au
phone: +61 2 6212 1183 (tie line 70 21183)

We do not inherit the earth from our ancestors,
we borrow it from our children. - S.M.A.R.T Person

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help