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]
Message-ID: <17512c98-b309-7b83-8c9c-cc8d43a495a2@suse.com>
Date:   Tue, 12 May 2020 06:24:20 +0200
From:   Jürgen Groß <jgross@...e.com>
To:     Stefano Stabellini <sstabellini@...nel.org>
Cc:     xen-devel@...ts.xenproject.org, linux-kernel@...r.kernel.org,
        Boris Ostrovsky <boris.ostrovsky@...cle.com>,
        stable@...r.kernel.org
Subject: Re: [PATCH] xen/pvcalls-back: test for errors when calling
 backend_connect()

On 11.05.20 23:41, Stefano Stabellini wrote:
> On Mon, 11 May 2020, Juergen Gross wrote:
>> backend_connect() can fail, so switch the device to connected only if
>> no error occurred.
>>
>> Fixes: 0a9c75c2c7258f2 ("xen/pvcalls: xenbus state handling")
>> Cc: stable@...r.kernel.org
>> Signed-off-by: Juergen Gross <jgross@...e.com>
> 
> Reviewed-by: Stefano Stabellini <sstabellini@...nel.org>
> 
> 
>> ---
>>   drivers/xen/pvcalls-back.c | 3 ++-
>>   1 file changed, 2 insertions(+), 1 deletion(-)
>>
>> diff --git a/drivers/xen/pvcalls-back.c b/drivers/xen/pvcalls-back.c
>> index cf4ce3e9358d..41a18ece029a 100644
>> --- a/drivers/xen/pvcalls-back.c
>> +++ b/drivers/xen/pvcalls-back.c
>> @@ -1088,7 +1088,8 @@ static void set_backend_state(struct xenbus_device *dev,
>>   		case XenbusStateInitialised:
>>   			switch (state) {
>>   			case XenbusStateConnected:
>> -				backend_connect(dev);
>> +				if (backend_connect(dev))
>> +					return;
> 
> Do you think it would make sense to WARN?

There already should be an error message (either due to a failed
grant mapping or a failed memory allocation).


Juergen

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ