From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by passt.top (Postfix) with ESMTP id 7C0965A0082 for ; Wed, 22 Feb 2023 14:02:34 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1677070953; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=C3dA/cRHt7t1CXN4b/3pzdMyHIXp1am6aayedXYY98U=; b=M6fyjJoBDu2lO0JHLVW3TxYve/pqV8urY6kP8UOGJImCKIR1mJ+Fm5kkAg9ew5r0r5oZaK NERX4Zr1N8Kbad0wuAnP0QWWTK2OKk+rJhX0mmUKdeOMCGXIK9aU1wRq+cS3wKJMEqy2u5 QdGXqf+YHZvt6DAuAHHU7ThJEL6S184= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-558-DsSBJvwlNRKwQ8lEElo0Gw-1; Wed, 22 Feb 2023 08:02:32 -0500 X-MC-Unique: DsSBJvwlNRKwQ8lEElo0Gw-1 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.rdu2.redhat.com [10.11.54.1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id E1D6A1C07821 for ; Wed, 22 Feb 2023 13:02:31 +0000 (UTC) Received: from maya.cloud.tilaa.com (unknown [10.33.32.23]) by smtp.corp.redhat.com (Postfix) with ESMTPS id C13E5404BEC0; Wed, 22 Feb 2023 13:02:31 +0000 (UTC) Date: Wed, 22 Feb 2023 14:02:20 +0100 From: Stefano Brivio To: Andrea Bolognani Subject: Re: [PATCH] qrap: Pass PCI device numbers to qemu in base 10, not in base 16 Message-ID: <20230222140220.43db3a68@elisabeth> In-Reply-To: References: <20230221192425.3745394-1-sbrivio@redhat.com> <20230222114508.10c0fd74@elisabeth> Organization: Red Hat MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Message-ID-Hash: YNMOYCWSA4SMYLPJQIGPCDVSJSS4MYAY X-Message-ID-Hash: YNMOYCWSA4SMYLPJQIGPCDVSJSS4MYAY X-MailFrom: sbrivio@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: passt-dev@passt.top, Alona Paz X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On Wed, 22 Feb 2023 04:47:32 -0800 Andrea Bolognani wrote: > On Wed, Feb 22, 2023 at 11:45:08AM +0100, Stefano Brivio wrote: > > On Wed, 22 Feb 2023 02:40:32 -0800 Andrea Bolognani wrote: > > > What I think needs to happen, is that each pci_dev should contain a > > > base value (16 for i440fx and 10 for q35), which is used both in the > > > strtol() call used to parse the command line produced by libvirt and > > > to decide whether %x or %i should be used with snprintf() to generate > > > qrap's own arguments. > > > > Right, I think it makes sense. Will you prepare a patch in this sense > > or should I try? > > Sure, I can give it a shot. It might take a bit, because the code is > kinda tricky and there is no test suite (that I'm aware of?) for this > part. Thanks! Right, sorry, no tests covering qrap at the moment, and the code is horrible. The KubeVirt integration might help if you have an environment ready. -- Stefano