linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Roman Zippel <zippel@linux-m68k.org>
To: Pavel Fedin <sonic_amiga@rambler.ru>
Cc: linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH] Full NLS support for HFS (classic) filesystem
Date: Tue, 31 May 2005 12:45:50 +0200 (CEST)	[thread overview]
Message-ID: <Pine.LNX.4.61.0505311156520.3728@scrub.home> (raw)
In-Reply-To: <429C68A0.20003@rambler.ru>

Hi,

On Tue, 31 May 2005, Pavel Fedin wrote:

>  This is my line. If "codepage" option is added in the future then the line
> would look like:
> 
> /dev/cdrom /mnt/cdrom iso9660,udf,hfsplus,hfs
> user,noauto,iocharset=koi8-r,codepage=866,hfscodepage=10007 0 0

Use different mount points. This is not a reason to create a lot of 
different options all doing the same.

> > Why do you build the extra translation tables? I'm not relly convinced this
> > is a kernel problem at all, but doing it more like fat would be more
> > acceptable (maybe just with some more sane defaults).
> 
>  I tried this in the beginning of my work and failed. As i can see some
> special tricky algorythm is used in order to find a file by name which depends
> on actual character code values (there are "<" and ">" conditions). It does
> not use string comparison at all. This algorythm requires the filename to be
> translated back from UNIX encoding to Mac encoding. I just can't apply another
> algorythm like "list all names in the directory, convert every name to UNIX
> encoding and compare", HFS simply does not behave this way.

This is not HFS specific problem, you have this problem with any fs using 
nls. fat does the comparison using the translated names, but that just 
means it may find the wrong file instead of no file.

>  Extra tables built on the fly ensure that every character in "codepage"  has
> its own unique equivalent in "iocharset", some equivalents are "invented" by
> marking all unmapped characters in "codepage" all unused characters in
> "iocharset" (those to which no one of "codepage"'s characters is mapped) and
> then maps unmapped characters to those unused characters. This works
> perfectly. I used this approach in my first attempt which introduced koi8-r
> only and were rejected by you several months ago.

Again, this is not HFS-specific. Create a dynamic nls translation module 
and use this from HFS, this code does not belong in HFS.
I would accept a translation similiar to fat, anything else has to be done 
at the nls layer.

>  Instead of two arguments (unsigned char *table, struct nls_table *nls) ? May
> be struct hfs_sb_info *sbi instead in order to avoid additional HFS_SB()
> macro?

No, superblock info is passed as "struct superblock *".

bye, Roman

  reply	other threads:[~2005-05-31 10:46 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <429B1E35.2040905@rambler.ru>
2005-05-30 11:50 ` [PATCH] Full NLS support for HFS (classic) filesystem Roman Zippel
2005-05-31 13:37   ` Pavel Fedin
2005-05-31 10:45     ` Roman Zippel [this message]
2005-05-31 19:35       ` Pavel Fedin
2005-05-31 12:13         ` Roman Zippel
2005-05-31 21:21           ` Pavel Fedin
2005-05-31 13:59             ` Roman Zippel
2005-05-31 14:49               ` Anton Altaparmakov
2005-05-31 15:28                 ` Roman Zippel
2005-06-02 13:34                 ` Pavel Fedin
2005-06-02  9:24                   ` Anton Altaparmakov
2005-06-03 13:34                     ` Pavel Fedin
2005-06-03  8:09                       ` Anton Altaparmakov
2005-06-06 13:15                         ` Pavel Fedin
2005-06-06 12:44                           ` Roman Zippel
2005-06-06 21:44                             ` Pavel Fedin
2005-06-06 14:44                               ` Roman Zippel
2005-06-08 18:08                                 ` Pavel Fedin
2005-06-01  0:26             ` Roman Zippel
     [not found]               ` <429F0869.4010805@rambler.ru>
     [not found]                 ` <Pine.LNX.4.61.0506021130290.3728@scrub.home>
2005-06-03 14:00                   ` Pavel Fedin
2005-06-09 23:47   ` George Anzinger
2005-05-30 14:05 Pavel Fedin

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=Pine.LNX.4.61.0505311156520.3728@scrub.home \
    --to=zippel@linux-m68k.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=sonic_amiga@rambler.ru \
    /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;
as well as URLs for NNTP newsgroup(s).