lkml.org 
[lkml]   [2017]   [Nov]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH 02/08] NTB: ntb_test: Add ntb_tool port tests

On 30/11/17 02:42 PM, Serge Semin wrote:
> +function find_pidx()
> +{
> + PORT=$1
> + PPATH=$2
> +
> + for ((i = 0; i < 64; i++)); do
> + PEER_DIR="$PPATH/peer$i"
> +
> + check_file ${PEER_DIR} || break
> +
> + PEER_PORT=$(read_file "${PEER_DIR}/port")
> + if [[ ${PORT} -eq $PEER_PORT ]]; then
> + echo $i
> + return 0
> + fi
> + done
> +
> + return 1
> +}

Actually, per my earlier comments on other messages. I think it would be
best if each of the patches in this series also included the relevant
changes to ntb_tool. Then just ditch the ntb_tool patch. For example,
this patch would include adding the "port" file to ntb_tool and the
relevant test to ntb_test.

Otherwise, when the ntb_tool patch is committed, the ntb_test breaks and
then is fixed in subsequent patches. In an ideal world, this would be
avoided in case we ever want to do a bisect involving ntb_test.

Logan

\
 
 \ /
  Last update: 2017-11-30 23:37    [W:0.112 / U:0.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site