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: <6e0256fa-6366-229c-c18d-ea8cfb6ef52d@cmss.chinamobile.com>
Date:   Thu, 16 Feb 2017 14:49:40 +0800
From:   Xiubo Li <lixiubo@...s.chinamobile.com>
To:     Andy Grover <agrover@...hat.com>,
        Greg KH <gregkh@...uxfoundation.org>
Cc:     mchristi@...hat.com, namei.unix@...il.com,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] uio: add UIO_MEM_CUSTOM support


>> buffer(uio0 --> map0). Currently the TCMU will using the fixed small
>> size map
>> area as the ring buffer, but this will be the bottleneck for high iops.
>>
>> Without knowing how large it is enough, so the new scheme will use the
>> fixed
>> small ring buffer area(about 64M ~ 128M) + dynamically "growing" ring
>> buffer
>> area(about 1.5G).
> The following code is in uio_mmap() in uio.c:
>
> if (idev->info->mmap) {
> 	ret = idev->info->mmap(idev->info, vma);
> 	return ret;
> }
>
> switch (idev->info->mem[mi].memtype) {
> 	case UIO_MEM_PHYS:
> 		return uio_mmap_physical(vma);
> 	case UIO_MEM_LOGICAL:
> 	case UIO_MEM_VIRTUAL:
> 		return uio_mmap_logical(vma);
> 	default:
> 		return -EINVAL;
> }
>
> We already have the equivalent of a CUSTOM memtype because TCMU sets the
> info->mmap fn, overriding uio's default handling choices in favor of its
> own.
For the driver like TCMU, the UIO_MEM_NONE could be used with
implementing its own ->mmap() magic, instead of adding new
UIO_MEM_CUSTOM. But will the semantic be clearer by using
_CUSTOM instead of _NONE  ?

Thanks,

BRs
Xiubo
> HTH -- Regards -- Andy
>



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ