linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: "André Almeida" <andrealmeid@igalia.com>
To: Nathan Chancellor <nathan@kernel.org>
Cc: Gabriel Krisman Bertazi <krisman@kernel.org>,
	Alexander Viro <viro@zeniv.linux.org.uk>,
	Christian Brauner <brauner@kernel.org>, Jan Kara <jack@suse.cz>,
	Theodore Ts'o <tytso@mit.edu>,
	Andreas Dilger <adilger.kernel@dilger.ca>,
	Hugh Dickins <hughd@google.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Jonathan Corbet <corbet@lwn.net>,
	smcv@collabora.com, kernel-dev@igalia.com,
	linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-ext4@vger.kernel.org, linux-mm@kvack.org,
	linux-doc@vger.kernel.org,
	Gabriel Krisman Bertazi <krisman@suse.de>,
	llvm@lists.linux.dev, linux-btrfs@vger.kernel.org,
	Chris Mason <clm@fb.com>
Subject: Re: [PATCH v8 8/9] tmpfs: Expose filesystem features via sysfs
Date: Thu, 31 Oct 2024 16:11:39 -0300	[thread overview]
Message-ID: <3386dc35-3ed1-4aab-abd2-42adfa25ddd9@igalia.com> (raw)
In-Reply-To: <c104f427-f9d9-498c-a719-ed6bf118226d@igalia.com>

Em 31/10/2024 14:31, André Almeida escreveu:
> Hi Nathan,
> 
> Em 31/10/2024 02:18, Nathan Chancellor escreveu:
>> Hi André,
>>

[...]

>> If there is any patch I can test or further information I can provide, I
>> am more than happy to do so.
>>

I found the issue, was just the DEVICE_ macro that I wasn't supposed to 
use inside of tmpfs, this diff solved the error for me, I will send a 
proper patch in a moment:

-- >8 --

diff --git a/mm/shmem.c b/mm/shmem.c
index 971e6f1184a5..db52c34d5020 100644
--- a/mm/shmem.c
+++ b/mm/shmem.c
@@ -5551,12 +5551,21 @@ EXPORT_SYMBOL_GPL(shmem_read_mapping_page_gfp);

  #if defined(CONFIG_SYSFS) && defined(CONFIG_TMPFS)
  #if IS_ENABLED(CONFIG_UNICODE)
-static DEVICE_STRING_ATTR_RO(casefold, 0444, "supported");
+static ssize_t casefold_show(struct kobject *kobj, struct 
kobj_attribute *a,
+                       char *buf)
+{
+               return sysfs_emit(buf, "supported\n");
+}
+static struct kobj_attribute tmpfs_attr_casefold = {
+               .attr = { .name = "casefold", .mode = 0444 },
+               .show = casefold_show,
+               .store = NULL,
+};
  #endif

  static struct attribute *tmpfs_attributes[] = {
  #if IS_ENABLED(CONFIG_UNICODE)
-       &dev_attr_casefold.attr.attr,
+       &tmpfs_attr_casefold.attr,
  #endif
         NULL
  };


  parent reply	other threads:[~2024-10-31 19:12 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-21 16:37 [PATCH v8 0/9] tmpfs: Add case-insensitive support for tmpfs André Almeida
2024-10-21 16:37 ` [PATCH v8 1/9] libfs: Create the helper function generic_ci_validate_strict_name() André Almeida
2024-10-21 16:37 ` [PATCH v8 2/9] ext4: Use generic_ci_validate_strict_name helper André Almeida
2024-10-21 16:37 ` [PATCH v8 3/9] unicode: Export latest available UTF-8 version number André Almeida
2024-10-21 16:37 ` [PATCH v8 4/9] unicode: Recreate utf8_parse_version() André Almeida
2024-10-21 16:37 ` [PATCH v8 5/9] libfs: Export generic_ci_ dentry functions André Almeida
2024-10-21 16:37 ` [PATCH v8 6/9] tmpfs: Add casefold lookup support André Almeida
2024-10-21 16:37 ` [PATCH v8 7/9] tmpfs: Add flag FS_CASEFOLD_FL support for tmpfs dirs André Almeida
2024-10-21 16:37 ` [PATCH v8 8/9] tmpfs: Expose filesystem features via sysfs André Almeida
2024-10-31  5:18   ` Nathan Chancellor
2024-10-31 17:31     ` André Almeida
2024-10-31 18:13       ` Nathan Chancellor
2024-10-31 19:11       ` André Almeida [this message]
2024-10-21 16:37 ` [PATCH v8 9/9] docs: tmpfs: Add casefold options André Almeida
2024-10-28 12:37 ` [PATCH v8 0/9] tmpfs: Add case-insensitive support for tmpfs Christian Brauner
2024-10-28 13:58   ` André Almeida

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3386dc35-3ed1-4aab-abd2-42adfa25ddd9@igalia.com \
    --to=andrealmeid@igalia.com \
    --cc=adilger.kernel@dilger.ca \
    --cc=akpm@linux-foundation.org \
    --cc=brauner@kernel.org \
    --cc=clm@fb.com \
    --cc=corbet@lwn.net \
    --cc=hughd@google.com \
    --cc=jack@suse.cz \
    --cc=kernel-dev@igalia.com \
    --cc=krisman@kernel.org \
    --cc=krisman@suse.de \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-ext4@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=llvm@lists.linux.dev \
    --cc=nathan@kernel.org \
    --cc=smcv@collabora.com \
    --cc=tytso@mit.edu \
    --cc=viro@zeniv.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox