<p>Patch set 1:<span style="border-radius: 3px; display: inline-block; margin: 0 2px; padding: 4px;background-color: #d4ffd4;">Code-Review +1</span></p><p><a href="https://gerrit.osmocom.org/11361">View Change</a></p><p>2 comments:</p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0;"><p><a href="https://gerrit.osmocom.org/#/c/11361/1/firmware/libcommon/source/card_emu.c">File firmware/libcommon/source/card_emu.c:</a></p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/#/c/11361/1/firmware/libcommon/source/card_emu.c@110">Patch Set #1, Line 110:</a> <code style="font-family:monospace,monospace">    OSMO_VALUE_STRING(TPDU_S_WAIT_CLA),</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">normally I'm not a big fan of OSMO_VALUE_STRING as the auto-generated string names are often way too long. However, in this case, the enum name is rather short and we can keep it.  Iwould consider "WAIT_INS" to be shorter but equally informative to the human reader.  The context already indicates it is a TPDU state and hence TPDU_S_ prefix doesn't add any non-redundant information</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/#/c/11361/1/firmware/libcommon/source/card_emu.c@671">Patch Set #1, Line 671:</a> <code style="font-family:monospace,monospace">  TRACE_DEBUG("%u: 7816 TPDU state %u (%s) -> %u (%s)\r\n", ch->num,</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">printing both the number and the string makes little sense, IMHO.  In other places [of osmocom projects] we normally print only either the number or the string representation, not both.  Please note that get_value_string will generate an "unknown 0x1234" string if the value doesn't have a corresponding string. The latter unfortunaly doesn't work if you call get_value_string() twice from function arguments, as the returned buffer is a static buffer.</p><p style="white-space: pre-wrap; word-wrap: break-word;">You can leave it as-is, but I'm juts sharing my thoughts. None of them are critical or prevent this from being merged.</p></li></ul></li></ul><p>To view, visit <a href="https://gerrit.osmocom.org/11361">change 11361</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.osmocom.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.osmocom.org/11361"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: simtrace2 </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-MessageType: comment </div>
<div style="display:none"> Gerrit-Change-Id: Id5104a2c3579dedb092c179748e9ed525673841c </div>
<div style="display:none"> Gerrit-Change-Number: 11361 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Kévin Redon <kredon@sysmocom.de> </div>
<div style="display:none"> Gerrit-Reviewer: Harald Welte <laforge@gnumonks.org> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins Builder (1000002) </div>
<div style="display:none"> Gerrit-Comment-Date: Mon, 15 Oct 2018 22:57:49 +0000 </div>
<div style="display:none"> Gerrit-HasComments: Yes </div>
<div style="display:none"> Gerrit-HasLabels: Yes </div>