<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:Calibri
}
--></style></head>
<body class='hmmessage'><div dir='ltr'>Thanks<BR>hash_cell is defined privately in dm_ioctl.c , so I cannot access it.<BR>also dm_get_mdptr ,is not extern so I can't access it neither.<BR> <BR>Thanks<BR>-gili<br> <BR><div>> Date: Mon, 6 Jul 2015 12:32:33 +0300<br>> From: kernel@kyup.com<br>> To: dm-devel@redhat.com<br>> Subject: Re: [dm-devel] Getting mapped device namw<br>> <br>> <br>> On 07/06/2015 12:20 PM, Gili B wrote:<br>> > hi<br>> > when a user run :<br>> > dmsetup create [device name] ....<br>> > Can a device mapper target find out the device name that the user entered ?<br>> <br>> Apparently the name is being associated with a hash_cell object, which<br>> in turn is associated with struct mapped_device in dm_hash_insert<br>> (called from dev_create, which is invoked as part of the create IOCTL).<br>> So presumably if you get an instance of struct mapped_device and then<br>> invoke dm_get_mdptr(md). What you'd get is a pointer to struct hash_cell<br>> <br>> > I need it for creating entries in proc for example.<br>> >  <br>> > Thanks<br>> > -gili<br>> >                                         <br>> > <br>> > <br>> > <br>> > --<br>> > dm-devel mailing list<br>> > dm-devel@redhat.com<br>> > https://www.redhat.com/mailman/listinfo/dm-devel<br>> > <br>> <br>> --<br>> dm-devel mailing list<br>> dm-devel@redhat.com<br>> https://www.redhat.com/mailman/listinfo/dm-devel<br></div>                                           </div></body>
</html>