lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 6 Sep 2010 08:06:40 -0700
From:	Richard Sharpe <realrichardsharpe@...il.com>
To:	Dmitry Torokhov <dmitry.torokhov@...il.com>
Cc:	"Nicholas A. Bellinger" <nab@...ux-iscsi.org>,
	Greg KH <gregkh@...e.de>,
	linux-scsi <linux-scsi@...r.kernel.org>,
	linux-kernel <linux-kernel@...r.kernel.org>,
	FUJITA Tomonori <fujita.tomonori@....ntt.co.jp>,
	Mike Christie <michaelc@...wisc.edu>,
	Christoph Hellwig <hch@....de>, Hannes Reinecke <hare@...e.de>,
	James Bottomley <James.Bottomley@...e.de>,
	Jens Axboe <axboe@...nel.dk>,
	Boaz Harrosh <bharrosh@...asas.com>
Subject: Re: [RFC 22/22] tcm_loop: Add multi-fabric Linux/SCSI LLD fabric module

On Mon, Sep 6, 2010 at 7:48 AM, Richard Sharpe
<realrichardsharpe@...il.com> wrote:
>> I think what you need is root_device_create() which will allocate a
>> device structure and assign ->release() that is implemented outside of
>> your module. This way your module may be unloaded even if there are
>> outstanding references to tcm_loop_primary device.
>
> I am embarrassed to admit that scst_local (or whatever its new name
> will be) probably has the same fault, as it too was based on
> scsi_debug ...
>
> However, I did a search of the 2.6.24.1 source tree and could not find

Typo alert: 2.6.34.1!

> any instances of root_device_create() being called nor defined. I just
> double and triple checked the spelling.
>
> Ahhh, I see why. A slightly different search suggests that it is
> root_device_register(const char *name).
>
> From include/linux/device.h:
>
> static inline struct device *root_device_register(const char *name)
> {
>        return __root_device_register(name, THIS_MODULE);
> }
>
> Was that the one you were thinking of?
>
>> The rest of devices you create needs to increment module counter or
>> otherwise ensure that their methods stay available until they are
>> cleaned up (->release() is called).
>
> OK, I need to check out how this is done.
>
>> Hope this helps.
>
> Sure does.
>
> --
> Regards,
> Richard Sharpe
>



-- 
Regards,
Richard Sharpe
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ