<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<small>Hi Patrick,<br>
<br>
Thanks for the review.<br>
</small><br>
<div class="moz-cite-prefix">On 08/14/2015 05:05 AM, Patrick
Williams wrote:<br>
</div>
<blockquote cite="mid:20150813233547.GC30624@asimov.austin.ibm.com"
type="cite">
<pre wrap="">On Wed, Aug 12, 2015 at 09:36:32PM +0530, Neelesh Gupta wrote:
</pre>
<blockquote type="cite">
<pre wrap="">+static void handle_prd_control_htmgt_passthru(struct control_msg
*send_msg,
+ struct control_msg *recv_msg)
</pre>
</blockquote>
<pre wrap="">...
</pre>
<blockquote type="cite">
<pre wrap="">+ pr_debug("CTRL: calling htmgt_pass_thru");
+ send_msg->response =3D call_htmgt_pass_thru(recv_msg->data_len,
+ recv_msg->data, &rsp_len,
+ send_msg->data);
+ send_msg->data_len =3D be16toh(rsp_len);
</pre>
</blockquote>
<pre wrap="">
Is recv_msg->data_len in the correct endianness prior to calling
call_htmgt_pass_thru? I don't see any obvious hto16be here, nor
in handle_prd_control.</pre>
</blockquote>
<br>
<small>'external/opal-prd/thunk.S'</small> <small>takes care of the
endianness of the arguments before<br>
invoking HBRT by branching to 'call_be'. It is good as long as
there is direct reference<br>
to the arguments but if the callee dereference them, then
'opal-prd' needs to take<br>
care of the byte ordering and use appropriate accessor..<br>
</small><br>
<blockquote cite="mid:20150813233547.GC30624@asimov.austin.ibm.com"
type="cite">
<pre wrap="">
</pre>
<blockquote type="cite">
<pre wrap="">+static void handle_prd_control_attr_override(struct control_msg
*send_msg,
+ struct control_msg *recv_msg)
</pre>
</blockquote>
<pre wrap="">...
</pre>
<blockquote type="cite">
<pre wrap="">+ pr_debug("CTRL: calling apply_attr_override");
+ send_msg->response =3D call_apply_attr_override(
+ recv_msg->data, recv_msg->data_len);
+ send_msg->data_len =3D 0;
+}
</pre>
</blockquote>
<pre wrap="">
Same endianness question here.
</pre>
<blockquote type="cite">
<pre wrap="">+
+/* TODO usage */
static void usage(const char *progname)
{
</pre>
</blockquote>
<pre wrap="">
Still TODO? Looks like you did something.</pre>
</blockquote>
<br>
<small>It was my local TODO .. :) and forgot to remove it before
posting,<br>
will correct this.<br>
<br>
Thanks,<br>
Neelesh.<br>
</small><br>
<blockquote cite="mid:20150813233547.GC30624@asimov.austin.ibm.com"
type="cite">
<pre wrap="">
</pre>
</blockquote>
<br>
</body>
</html>