Ahmed S. Darwish wrote: > Remove unnecessary kmalloc casts in drivers/char/tty_io.c > > Signed-off-by: Ahmed Darwish <[email protected]> > if (!*ltp_loc) { > - ltp = (struct ktermios *) kmalloc(sizeof(struct ktermios), > - GFP_KERNEL); > + ltp = kmalloc(sizeof(struct ktermios), GFP_KERNEL); ^^^^^^^ > if (!ltp) > goto free_mem_out; > memset(ltp, 0, sizeof(struct ktermios)); ^^^^^^ kzalloc > if (!*o_ltp_loc) { > - o_ltp = (struct ktermios *) > - kmalloc(sizeof(struct ktermios), GFP_KERNEL); > + o_ltp = kmalloc(sizeof(struct ktermios), GFP_KERNEL); ^^^^^^^ > if (!o_ltp) > goto free_mem_out; > memset(o_ltp, 0, sizeof(struct ktermios)); ^^^^^^ kzalloc HTH Eike
Attachment:
pgpaxLmwKwj7V.pgp
Description: PGP signature
- Follow-Ups:
- Re: [PATCH 2.6.20-rc3] TTY_IO: Remove unnecessary kmalloc casts
- From: "Ahmed S. Darwish" <[email protected]>
- Re: [PATCH 2.6.20-rc3] TTY_IO: Remove unnecessary kmalloc casts
- References:
- [PATCH 2.6.20-rc3] TTY_IO: Remove unnecessary kmalloc casts
- From: "Ahmed S. Darwish" <[email protected]>
- [PATCH 2.6.20-rc3] TTY_IO: Remove unnecessary kmalloc casts
- Prev by Date: Re: [PATCHSET 1][PATCH 0/6] Filesystem AIO read/write
- Next by Date: [PATCH] backlight control for Frontpath ProGear HX1050+
- Previous by thread: Re: [PATCH 2.6.20-rc3] TTY_IO: Remove unnecessary kmalloc casts
- Next by thread: Re: [PATCH 2.6.20-rc3] TTY_IO: Remove unnecessary kmalloc casts
- Index(es):