Problem with rust module

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi, all

I try to compile a  sample rust module with below Makefile:

obj-m += rust_minimal.o
all:
    make -C ../.. M=$(PWD) modules

but failed with below message:

ERROR: modpost: too long symbol
"_RNvNtNtCschHAZg3Q02y_6kernel5print14format_strings4INFO"
[/linux-rust/samples/rust/rust_minimal.ko]

But I see there are many long symbols in Module.symvers. So I guess there's
something wrong with modpost.

The relevant code is as follows:
   list_for_each_entry(s, &mod->unresolved_symbols, list) {
          if (!s->module)
              continue;
          if (!s->crc_valid) {
              warn("\"%s\" [%s.ko] has no CRC!\n",
                  s->name, mod->name);
              continue;
          }
          if (strlen(s->name) >= MODULE_NAME_LEN) {
              error("too long symbol \"%s\" [%s.ko]\n",
                    s->name, mod->name);
              break;
          }

 MODULE_NAME_LEN is weird. Is the code right?

Thanks.




[Index of Archives]     [Linux&nblp;USB Development]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite Secrets]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux