lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Mon, 27 Apr 2015 15:01:30 +0200
From:	Michael Mueller <mimu@...ux.vnet.ibm.com>
To:	Cornelia Huck <cornelia.huck@...ibm.com>
Cc:	Christian Borntraeger <borntraeger@...ibm.com>,
	qemu-devel@...gnu.org, kvm@...r.kernel.org,
	linux-s390@...r.kernel.org, linux-kernel@...r.kernel.org,
	Eduardo Habkost <ehabkost@...hat.com>,
	Gleb Natapov <gleb@...nel.org>, Alexander Graf <agraf@...e.de>,
	Daniel Hansel <daniel.hansel@...ux.vnet.ibm.com>,
	"Jason J. Herne" <jjherne@...ux.vnet.ibm.com>,
	Paolo Bonzini <pbonzini@...hat.com>,
	Richard Henderson <rth@...ddle.net>,
	Andreas Faerber <afaerber@...e.de>
Subject: Re: [Qemu-devel] [PATCH v5 11/17] target-s390x: Add KVM VM
 attribute interface for S390 CPU models

On Mon, 27 Apr 2015 14:19:13 +0200
Cornelia Huck <cornelia.huck@...ibm.com> wrote:

> > > >> Would it make sense to do the cast here....  
> > > > 
> > > > cpu_model_get/set() is used to handle both attributes,
> > > > KVM_S390_VM_CPU_MACHINE and KVM_S390_VM_CPU_PROCESSOR.
> > > > Both require a different type in the signature, (S390ProcessorProps*)
> > > > and (S390MachineProps*). Adding both as parameters seems to be odd
> > > > and would require additionally logic in the function.
> > > > Thus I think doing the cast outside is just the right thing to do.  
> > > 
> > > So what about a void pointer then as parameter?
> > > I prefer a pointer for qemu process memory over uint64_t as part of the 
> > > function interface. This makes it somewhat clearer that this is an
> > > address within QEMU. Both ways will certainly work, though.  
> > 
> > The interface calls are:
> > 
> > int kvm_s390_get_machine_props(KVMState *s, S390MachineProps *prop)
> > int kvm_s390_get_processor_props(S390ProcessorProps *prop)
> > 
> > cpu_model_get/set() are just static helpers.  
> 
> So this makes them internal calls...
> 
> >   
> > > 
> > > Conny, I guess you will pick up the patches. Any preference?  
> 
> ...and I'd prefer using a void pointer for them.

Ok, I will make void pointers then to emphasize their address characteristics.

Michael

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ