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] [thread-next>] [day] [month] [year] [list]
Message-ID: <YFPAjYDOCXqpqgV8@gmail.com>
Date:   Thu, 18 Mar 2021 14:05:17 -0700
From:   Eric Biggers <ebiggers@...nel.org>
To:     Shreeya Patel <shreeya.patel@...labora.com>
Cc:     krisman@...labora.com, jaegeuk@...nel.org, yuchao0@...wei.com,
        tytso@....edu, adilger.kernel@...ger.ca, drosen@...gle.com,
        linux-kernel@...r.kernel.org, linux-fsdevel@...r.kernel.org,
        kernel@...labora.com, andre.almeida@...labora.com
Subject: Re: [PATCH v2 4/4] fs: unicode: Add utf8 module and a unicode layer

On Thu, Mar 18, 2021 at 07:03:05PM +0530, Shreeya Patel wrote:
> +struct unicode_ops {
> +	struct module *owner;
> +	int (*validate)(const struct unicode_map *um, const struct qstr *str);
> +	int (*strncmp)(const struct unicode_map *um, const struct qstr *s1,
> +		       const struct qstr *s2);
> +	int (*strncasecmp)(const struct unicode_map *um, const struct qstr *s1,
> +			   const struct qstr *s2);
> +	int (*strncasecmp_folded)(const struct unicode_map *um, const struct qstr *cf,
> +				  const struct qstr *s1);
> +	int (*normalize)(const struct unicode_map *um, const struct qstr *str,
> +			 unsigned char *dest, size_t dlen);
> +	int (*casefold)(const struct unicode_map *um, const struct qstr *str,
> +			unsigned char *dest, size_t dlen);
> +	int (*casefold_hash)(const struct unicode_map *um, const void *salt,
> +			     struct qstr *str);
> +	struct unicode_map* (*load)(const char *version);
> +};

Indirect calls are expensive these days, especially due to the Spectre
mitigations.  Would it make sense to use static calls
(include/linux/static_call.h) instead for this?

- Eric

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ