Linux MIPS Architecture development
 help / color / mirror / Atom feed
From: Matej Kupljen <matej.kupljen@ultra.si>
To: Jordan Crouse <jordan.crouse@amd.com>
Cc: linux-mips@linux-mips.org, ralf@linux-mips.org
Subject: Re: [PATCH] ALCHEMY:  Alchemy Camera Interface (CIM) driver
Date: Mon, 05 Dec 2005 09:49:27 +0100	[thread overview]
Message-ID: <1133772567.2377.11.camel@localhost.localdomain> (raw)
In-Reply-To: <20051202190635.GI28227@cosmic.amd.com>

Hi

> A driver for the AU1200 Camera Interface (CIM).  

Great news!

> I'm sending up right now, so comments and flames are definately
> welcome.

Wouldn't it be wise to support V4L2?
This way, many existing application could use AU1200s camera interface.


> +int __init
> +au1xxxcim_init(void)
> +{
> +	int retval, error;
> +	unsigned long page;
> +	CAMERA_RUNTIME *cam_init;
> +	CAMERA *cim_ptr;
> +
> +	cam_init = &cam_base;
> +	cam_init->cmos_camera = OrigCimArryPtr + prev_mode;
> +	cim_ptr = cam_init->cmos_camera;
> +
> +	/*Allocating memory for MMAP */
> +	mem_buf = (unsigned long *)Camera_mem_alloc(2 * MAX_FRAME_SIZE);
> +	if (mem_buf == NULL) {
> +		printk(KERN_ERR "MMAP unable to allocate memory \n");
> +	}

IMHO this is a waste of memory, because if the user is going to use
the camera in 320x240 mode and this allocates memory for the biggest
size. Wouldn't it be better to set some default configuration and
allocate memory for this? Later if the user changes the mode those
pages are freed and new (for requested size) are allocated.
Or even allocate memory AFTER the configuration has been set?

BR,
Matej

  reply	other threads:[~2005-12-05  8:51 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-02 19:06 [PATCH] ALCHEMY: Alchemy Camera Interface (CIM) driver Jordan Crouse
2005-12-05  8:49 ` Matej Kupljen [this message]
2005-12-05 15:06   ` Jordan Crouse
2005-12-05  9:28 ` [PATCH] " Komal Shah

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1133772567.2377.11.camel@localhost.localdomain \
    --to=matej.kupljen@ultra.si \
    --cc=jordan.crouse@amd.com \
    --cc=linux-mips@linux-mips.org \
    --cc=ralf@linux-mips.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox