From patchwork Tue Jun 6 16:31:41 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Huth X-Patchwork-Id: 771945 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3whxz900X3z9s4q for ; Wed, 7 Jun 2017 02:31:49 +1000 (AEST) Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 3whxz867lBzDqL2 for ; Wed, 7 Jun 2017 02:31:48 +1000 (AEST) X-Original-To: slof@lists.ozlabs.org Delivered-To: slof@lists.ozlabs.org Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 3whxz52kcCzDqGr for ; Wed, 7 Jun 2017 02:31:45 +1000 (AEST) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 6750F20A8A for ; Tue, 6 Jun 2017 16:31:43 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 6750F20A8A Authentication-Results: ext-mx06.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx06.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=thuth@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 6750F20A8A Received: from thh440s.redhat.com (ovpn-116-238.ams2.redhat.com [10.36.116.238]) by smtp.corp.redhat.com (Postfix) with ESMTP id BAA2F17569 for ; Tue, 6 Jun 2017 16:31:42 +0000 (UTC) From: Thomas Huth To: slof@lists.ozlabs.org Date: Tue, 6 Jun 2017 18:31:41 +0200 Message-Id: <1496766701-30411-1-git-send-email-thuth@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.30]); Tue, 06 Jun 2017 16:31:43 +0000 (UTC) Subject: [SLOF] [PATCH] Increase MAX-ALIAS to 10 X-BeenThere: slof@lists.ozlabs.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Patches for https://github.com/aik/SLOF" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: slof-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "SLOF" It's not obvious for the normal user why the alias enumeration should stop at the digit '7' already, so let's allow '8' and '9', too, by bumping the MAX-ALIAS constant to 10. Also remove the unnecessary duplicate of this value from qemu-bootlist.fs. Signed-off-by: Thomas Huth --- board-qemu/slof/qemu-bootlist.fs | 1 - slof/fs/node.fs | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/board-qemu/slof/qemu-bootlist.fs b/board-qemu/slof/qemu-bootlist.fs index 60dd29d..6a4005d 100644 --- a/board-qemu/slof/qemu-bootlist.fs +++ b/board-qemu/slof/qemu-bootlist.fs @@ -13,7 +13,6 @@ defer set-boot-device defer add-boot-device -8 CONSTANT MAX-ALIAS : add-boot-aliases ( str -- ) 2dup add-boot-device ( $str ) MAX-ALIAS 1 DO diff --git a/slof/fs/node.fs b/slof/fs/node.fs index 22bf77b..3b079e4 100644 --- a/slof/fs/node.fs +++ b/slof/fs/node.fs @@ -324,7 +324,7 @@ defer find-node \ return next available name for aliasing or \ false if more than MAX-ALIAS aliases found -8 CONSTANT MAX-ALIAS +d# 10 CONSTANT MAX-ALIAS 1 VALUE alias-ind : get-next-alias ( $alias-name -- $next-alias-name|FALSE ) 2dup find-alias IF