From nobody Fri Mar 29 10:18:23 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1617803412; cv=none; d=zohomail.com; s=zohoarc; b=NRk7/GXpKayxkVPkM3XdVr88I0BFZgBnwp5+w31q7mJUTXygaro6huTIOnM2OB9mm1nQaMmNRaFdCFDcVjiVpd80g26fYJWCHjSX8sgPLv4Q/Ve9ARjp5Hv0y5uJBNOWAWMBhOiplYrjx1TCdloc3LS83U/MWElAZIzaJhqkfLA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1617803412; h=Content-Type:Content-Transfer-Encoding:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=rrqkozfgOv8IARdoUwjqeknb/UuMwcx4QkGaUXx+f2g=; b=F7bDtTbb4W3qVEBlDQnBtUiqaTTsGBS2hQtsJY2AInYqu2IfW+K3aZ5l8AcERA6Mo4bOLRuCxeH2OfvES6o2/CKVonJc1Tv363MyNubnMJdBD/94t7yW9oOCLa9wjMjwyFjXq3OLoAkbaSuWSN1nT/bNLsoyVyubuz5k+v7N80s= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1617803412822766.7882001441794; Wed, 7 Apr 2021 06:50:12 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-286-mklJ7yYIMaeLCZfD8_orsA-1; Wed, 07 Apr 2021 09:50:09 -0400 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 9EBBA107ACCA; Wed, 7 Apr 2021 13:50:03 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 07AA160C5C; Wed, 7 Apr 2021 13:50:00 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 86AD35533F; Wed, 7 Apr 2021 13:49:56 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 137Dnsib022943 for ; Wed, 7 Apr 2021 09:49:54 -0400 Received: by smtp.corp.redhat.com (Postfix) id 60AAE5D742; Wed, 7 Apr 2021 13:49:54 +0000 (UTC) Received: from localhost.localdomain.com (ovpn-115-28.ams2.redhat.com [10.36.115.28]) by smtp.corp.redhat.com (Postfix) with ESMTP id 851BB5D6CF; Wed, 7 Apr 2021 13:49:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1617803411; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=rrqkozfgOv8IARdoUwjqeknb/UuMwcx4QkGaUXx+f2g=; b=hG+9uvIwZ5Ye/l3GNFxlEQ8smYNAIYGscAZxxBWv8ZC93Dqo+vr6NsHjQhpLPlaysiTaG0 peVXo7ol0gnmwkI/A7U5tm41lNYLmCMRGDwZ4NllOZvzFOlOcQXb/uYPC5R72yxfmkXGpD kDGIYjKXq3bK3JRGd5rPzjU/xsKut24= X-MC-Unique: mklJ7yYIMaeLCZfD8_orsA-1 From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= To: libvir-list@redhat.com Subject: [libvirt PATCH] conf: add ABI stability check for disk rotation rate Date: Wed, 7 Apr 2021 14:49:47 +0100 Message-Id: <20210407134947.389937-1-berrange@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Signed-off-by: Daniel P. Berrang=C3=A9 Reviewed-by: J=C3=A1n Tomko --- src/conf/domain_conf.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 875edcbff3..83415f9271 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -22313,6 +22313,13 @@ virDomainDiskDefCheckABIStability(virDomainDiskDef= Ptr src, return false; } =20 + if (src->rotation_rate !=3D dst->rotation_rate) { + virReportError(VIR_ERR_CONFIG_UNSUPPORTED, + _("Target disk rotation rate %u RPM does not match = source %u RPM"), + dst->rotation_rate, src->rotation_rate); + return false; + } + if (!virDomainVirtioOptionsCheckABIStability(src->virtio, dst->virtio)) return false; =20 --=20 2.30.2