From mboxrd@z Thu Jan 1 00:00:00 1970 From: romeusmeister@gmail.com (Roman Storozhenko) Date: Sun, 18 Jun 2017 17:38:36 +0300 Subject: Is there any way to add an =?utf-8?Q?attri?= =?utf-8?Q?bute_under_sysfs_at_the_=E2=80=9Cplatform=E2=80=9D?= level? Message-ID: <20170618143836.GA7147@home> To: kernelnewbies@lists.kernelnewbies.org List-Id: kernelnewbies.lists.kernelnewbies.org Hello everybody! I am trying to modify "pcspkr" driver undere linux kernel source tree. I added a new line there: sample_id_dir = kobject_create_and_add("devices/platform/pcspkr/sample", NULL); It works and creates kobject without errors. I checked this in the driver code and in the dmesg output. But "sample" catalog isn't appear under "/sys/devices/platform/pcspkr/". What is wrong with that code ? Thanks in advance, Roman Storozhenko