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  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 4 Nov 2008 11:16:31 -0800
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	Boaz Harrosh <bharrosh@...asas.com>
Cc:	James.Bottomley@...senPartnership.com, michaelc@...wisc.edu,
	fujita.tomonori@....ntt.co.jp, jeff@...zik.org,
	osd-dev@...n-osd.org, linux-scsi@...r.kernel.org,
	linux-kernel@...r.kernel.org, Sami.Iren@...gate.com, pw@...d.com
Subject: Re: [PATCH 04/18] libosd: OSDv1 preliminary implementation

On Tue,  4 Nov 2008 18:44:29 +0200
Boaz Harrosh <bharrosh@...asas.com> wrote:

> Implementation of the most basic OSD functionality and
> infrastructure. Mainly Format, Create/Remove Partition,
> Create/Remove Object, and read/write.
> 
>
> ...
>
> +struct osd_request *_osd_request_alloc(gfp_t gfp)
> +{
> +	struct osd_request *or;
> +
> +	/* TODO: Use mempool with one saved request */
> +	or = kzalloc(sizeof(*or), gfp);
> +	return or;
> +}
> +
> +void _osd_request_free(struct osd_request *or)
> +{
> +	kfree(or);
> +}

These two functions can/should be made static.  Please generally check
for this.

Also it'd probably make sense to declare both these inline.  The
compiler _shoudl_ get it right, but stranger things have happened...

>
> ...
>
> +/*
> + * If osd_finalize_request() was called but the request was not executed through
> + * the block layer, then we must release BIOs.
> + */
> +static void _abort_unexecuted_bios(struct request *rq)
> +{
> +	struct bio *bio;
> +
> +	while ((bio = rq->bio) != NULL) {
> +		rq->bio = bio->bi_next;
> +		bio_endio(bio, 0);
> +	}
> +}

Boy, that's a scary function.  bye-bye data.


--
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