[PATCH 1/3] staging: android: ashmem.c: 'spaces preferred around that -' style issue
fix a CHECK style issue by checkpatch.pl with --strict: spaces preferred around that '-' Signed-off-by: Peng Sun --- drivers/staging/android/ashmem.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/staging/android/ashmem.c b/drivers/staging/android/ashmem.c index 60200a3..b340ddc 100644 --- a/drivers/staging/android/ashmem.c +++ b/drivers/staging/android/ashmem.c @@ -618,7 +618,8 @@ static int ashmem_pin(struct ashmem_area *asma, size_t pgstart, size_t pgend) /* Case #3: We overlap from the rear, so adjust it */ if (range->pgend <= pgend) { - range_shrink(range, range->pgstart, pgstart-1); + range_shrink(range, range->pgstart, +pgstart - 1); continue; } -- 1.9.1 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 2/3] staging: android: ashmem.c: 'No space necessary after' style issue
fix two CHECK issues by checkpatch.pl with --strict: No space is necessary after a cast Signed-off-by: Peng Sun --- drivers/staging/android/ashmem.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/android/ashmem.c b/drivers/staging/android/ashmem.c index b340ddc..1312600 100644 --- a/drivers/staging/android/ashmem.c +++ b/drivers/staging/android/ashmem.c @@ -716,7 +716,7 @@ static int ashmem_pin_unpin(struct ashmem_area *asma, unsigned long cmd, if (unlikely((pin.offset | pin.len) & ~PAGE_MASK)) return -EINVAL; - if (unlikely(((__u32) -1) - pin.offset < pin.len)) + if (unlikely(((__u32)-1) - pin.offset < pin.len)) return -EINVAL; if (unlikely(PAGE_ALIGN(asma->size) < pin.offset + pin.len)) @@ -760,7 +760,7 @@ static long ashmem_ioctl(struct file *file, unsigned int cmd, unsigned long arg) ret = -EINVAL; if (!asma->file) { ret = 0; - asma->size = (size_t) arg; + asma->size = (size_t)arg; } break; case ASHMEM_GET_SIZE: -- 1.9.1 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 3/3] staging: android: ashmem.c: 'Alignment' style issue
fix two CHECK issues by checkpatch.pl with --strict: Alignment should match open parenthesis Signed-off-by: Peng Sun --- drivers/staging/android/ashmem.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/staging/android/ashmem.c b/drivers/staging/android/ashmem.c index 1312600..d786ec1 100644 --- a/drivers/staging/android/ashmem.c +++ b/drivers/staging/android/ashmem.c @@ -834,16 +834,16 @@ static int __init ashmem_init(void) int ret; ashmem_area_cachep = kmem_cache_create("ashmem_area_cache", - sizeof(struct ashmem_area), - 0, 0, NULL); + sizeof(struct ashmem_area), + 0, 0, NULL); if (unlikely(!ashmem_area_cachep)) { pr_err("failed to create slab cache\n"); return -ENOMEM; } ashmem_range_cachep = kmem_cache_create("ashmem_range_cache", - sizeof(struct ashmem_range), - 0, 0, NULL); + sizeof(struct ashmem_range), + 0, 0, NULL); if (unlikely(!ashmem_range_cachep)) { pr_err("failed to create slab cache\n"); return -ENOMEM; -- 1.9.1 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 0/3] staging: android: ashmem.c: fix several coding style issues
patches based on linux-next next-20150826 Corrections based on checkpatch.pl with --strict Peng Sun (3): staging: android: ashmem.c: 'spaces preferred around that -' style issue staging: android: ashmem.c: 'No space necessary after' style issue staging: android: ashmem.c: 'Alignment' style issue drivers/staging/android/ashmem.c | 15 --- 1 file changed, 8 insertions(+), 7 deletions(-) -- 1.9.1 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: [PATCH 2/2] android, lmk: Reverse the order of setting TIF_MEMDIE and sending SIGKILL.
On Thu 27-08-15 00:34:47, Tetsuo Handa wrote: > Reposting updated version as it turned out that we can call do_send_sig_info() > with task_lock held. ;-) ( http://marc.info/?l=linux-mm&m=144059948628905&w=2 > ) > > Tetsuo Handa wrote: > > Should selected_tasksize be added to rem even when TIF_MEMDIE was not set? > Commit e1099a69a624 "android, lmk: avoid setting TIF_MEMDIE if process > has already exited" changed not to add selected_tasksize to rem. But I > noticed that rem is initialized to 0 and there is only one addition > (i.e. rem += selected_tasksize means rem = selected_tasksize) since > commit 7dc19d5affd7 "drivers: convert shrinkers to new count/scan API". > I don't know what values we should return, but this patch restores > pre commit e1099a69a624 because omitting a call to mark_oom_victim() > due to race will not prevent from reclaiming memory because we already > sent SIGKILL. > > >From b7075abd3a1e903e88f1755c68adc017d2125b0d Mon Sep 17 00:00:00 2001 > From: Tetsuo Handa > Date: Thu, 27 Aug 2015 00:13:57 +0900 > Subject: [PATCH 2/2] android, lmk: Send SIGKILL before setting TIF_MEMDIE. > > It was observed that setting TIF_MEMDIE before sending SIGKILL at > oom_kill_process() allows memory reserves to be depleted by allocations > which are not needed for terminating the OOM victim. > > This patch reverts commit 6bc2b856bb7c ("staging: android: lowmemorykiller: > set TIF_MEMDIE before send kill sig"), for oom_kill_process() was updated > to send SIGKILL before setting TIF_MEMDIE. > > Signed-off-by: Tetsuo Handa Acked-by: Michal Hocko > --- > drivers/staging/android/lowmemorykiller.c | 17 ++--- > 1 file changed, 6 insertions(+), 11 deletions(-) > > diff --git a/drivers/staging/android/lowmemorykiller.c > b/drivers/staging/android/lowmemorykiller.c > index d5d25e4..af604cf 100644 > --- a/drivers/staging/android/lowmemorykiller.c > +++ b/drivers/staging/android/lowmemorykiller.c > @@ -156,26 +156,21 @@ next: > } > if (selected) { > task_lock(selected); > - if (!selected->mm) { > - /* Already exited, cannot do mark_tsk_oom_victim() */ > - task_unlock(selected); > - goto out; > - } > + lowmem_print(1, "send sigkill to %d (%s), adj %hd, size %d\n", > + selected->pid, selected->comm, > + selected_oom_score_adj, selected_tasksize); > + send_sig(SIGKILL, selected, 0); > /* >* FIXME: lowmemorykiller shouldn't abuse global OOM killer >* infrastructure. There is no real reason why the selected >* task should have access to the memory reserves. >*/ > - mark_oom_victim(selected); > - lowmem_print(1, "send sigkill to %d (%s), adj %hd, size %d\n", > - selected->pid, selected->comm, > - selected_oom_score_adj, selected_tasksize); > + if (selected->mm) > + mark_oom_victim(selected); > task_unlock(selected); > lowmem_deathpending_timeout = jiffies + HZ; > - send_sig(SIGKILL, selected, 0); > rem += selected_tasksize; > } > -out: > lowmem_print(4, "lowmem_scan %lu, %x, return %lu\n", >sc->nr_to_scan, sc->gfp_mask, rem); > rcu_read_unlock(); > -- > 1.8.3.1 -- Michal Hocko SUSE Labs ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
waiting for your reply soon
Remember! It won't sell if nobody knows you have it. You are receiving this email because we wish you to use our target email marketing service. We specialize in providing target email marketing services. We have worked on a number of projects and campaigns, all our packages are tailor made and designed according to your requirements. Increase your client base and market your product to millions or l et us bring the buying leads for you! Our goal is to increase your business sales 2-5 times than now. If you would require more information please send us an email and we would be glad to discuss the project requirements with you! Kind Regards Louis Contact: vivian...@sina.com Remember! It won't sell if nobody knows you have it. ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 0/3] drivers/staging: Use %pM format specifier to print mac address
printk() supports %pM format specifier for printing 6-byte MAC/FDDI addresses in hex notation small buffers, let's use it intead of %x:%x... This patch set provides fixes for the following drivers: * rtl8188eu * rtl8723au * wilc1000 Alexander Kuleshov (3): staging/rtl8188eu: Use %pM format specifier to print mac address staging/rtl8723au: Use %pM format specifier to print mac address staging/wilc1000: Use %pM format specifier to print mac address drivers/staging/rtl8188eu/core/rtw_mlme_ext.c | 5 ++--- drivers/staging/rtl8723au/core/rtw_mlme_ext.c | 7 ++- drivers/staging/wilc1000/host_interface.c | 6 +++--- drivers/staging/wilc1000/linux_mon.c | 2 +- drivers/staging/wilc1000/linux_wlan.c | 3 +-- 5 files changed, 9 insertions(+), 14 deletions(-) -- 2.5.0 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 1/3] staging/rtl8188eu: Use %pM format specifier to print mac address
printk() supports %pM format specifier for printing 6-byte MAC/FDDI addresses in hex notation small buffers, let's use it intead of %x:%x... Signed-off-by: Alexander Kuleshov --- drivers/staging/rtl8188eu/core/rtw_mlme_ext.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/staging/rtl8188eu/core/rtw_mlme_ext.c b/drivers/staging/rtl8188eu/core/rtw_mlme_ext.c index a0b8f66..5c2dacf 100644 --- a/drivers/staging/rtl8188eu/core/rtw_mlme_ext.c +++ b/drivers/staging/rtl8188eu/core/rtw_mlme_ext.c @@ -5384,9 +5384,8 @@ u8 set_stakey_hdl(struct adapter *padapter, u8 *pbuf) cam_id = psta->mac_id + 3;/* 0~3 for default key, cmd_id = macid + 3, macid = aid+1; */ - DBG_88E("Write CAM, mac_addr =%x:%x:%x:%x:%x:%x, cam_entry=%d\n", pparm->addr[0], - pparm->addr[1], pparm->addr[2], pparm->addr[3], pparm->addr[4], - pparm->addr[5], cam_id); + DBG_88E("Write CAM, mac_addr =%pM, cam_entry=%d\n", + pparm->addr, cam_id); write_cam(padapter, cam_id, ctrl, pparm->addr, pparm->key); -- 2.5.0 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 2/3] staging/rtl8723au: Use %pM format specifier to print mac address
printk() supports %pM format specifier for printing 6-byte MAC/FDDI addresses in hex notation small buffers, let's use it intead of %x:%x... Signed-off-by: Alexander Kuleshov --- drivers/staging/rtl8723au/core/rtw_mlme_ext.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/staging/rtl8723au/core/rtw_mlme_ext.c b/drivers/staging/rtl8723au/core/rtw_mlme_ext.c index be9a3d5..fca22ba 100644 --- a/drivers/staging/rtl8723au/core/rtw_mlme_ext.c +++ b/drivers/staging/rtl8723au/core/rtw_mlme_ext.c @@ -5934,11 +5934,8 @@ int set_stakey_hdl23a(struct rtw_adapter *padapter, const u8 *pbuf) macid = aid+1; */ cam_id = psta->mac_id + 3; - DBG_8723A("Write CAM, mac_addr =%x:%x:%x:%x:%x:%x, " - "cam_entry =%d\n", pparm->addr[0], - pparm->addr[1], pparm->addr[2], - pparm->addr[3], pparm->addr[4], - pparm->addr[5], cam_id); + DBG_8723A("Write CAM, mac_addr =%pM, " + "cam_entry =%d\n", pparm->addr, cam_id); rtl8723a_cam_write(padapter, cam_id, ctrl, pparm->addr, pparm->key); -- 2.5.0 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH 3/3] staging/wilc1000: Use %pM format specifier to print mac address
printk() supports %pM format specifier for printing 6-byte MAC/FDDI addresses in hex notation small buffers, let's use it intead of %x:%x... Signed-off-by: Alexander Kuleshov --- drivers/staging/wilc1000/host_interface.c | 6 +++--- drivers/staging/wilc1000/linux_mon.c | 2 +- drivers/staging/wilc1000/linux_wlan.c | 3 +-- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/drivers/staging/wilc1000/host_interface.c b/drivers/staging/wilc1000/host_interface.c index 6b10bbb..48ee908 100644 --- a/drivers/staging/wilc1000/host_interface.c +++ b/drivers/staging/wilc1000/host_interface.c @@ -854,7 +854,7 @@ static s32 Handle_SetMacAddress(void *drvHandler, tstrHostIfSetMacAddress *pstrH strWID.enuWIDtype = WID_STR; strWID.ps8WidVal = mac_buf; strWID.s32ValueSize = ETH_ALEN; - PRINT_D(GENERIC_DBG, "mac addr = :%x:%x:%x:%x:%x:%x\n", strWID.ps8WidVal[0], strWID.ps8WidVal[1], strWID.ps8WidVal[2], strWID.ps8WidVal[3], strWID.ps8WidVal[4], strWID.ps8WidVal[5]); + PRINT_D(GENERIC_DBG, "mac addr = :%pM\n", strWID.ps8WidVal); /*Sending Cfg*/ s32Error = SendConfigPkt(SET_CFG, &strWID, 1, true, (u32)pstrWFIDrv); if (s32Error) { @@ -1965,8 +1965,8 @@ static s32 Handle_Connect(void *drvHandler, tstrHostIFconnectAttr *pstrHostIFcon if (pstrHostIFconnectAttr->pu8bssid != NULL) { WILC_memcpy(u8ConnectedSSID, pstrHostIFconnectAttr->pu8bssid, ETH_ALEN); - PRINT_D(GENERIC_DBG, "save Bssid = %x:%x:%x:%x:%x:%x\n", (pstrHostIFconnectAttr->pu8bssid[0]), (pstrHostIFconnectAttr->pu8bssid[1]), (pstrHostIFconnectAttr->pu8bssid[2]), (pstrHostIFconnectAttr->pu8bssid[3]), (pstrHostIFconnectAttr->pu8bssid[4]), (pstrHostIFconnectAttr->pu8bssid[5])); - PRINT_D(GENERIC_DBG, "save bssid = %x:%x:%x:%x:%x:%x\n", (u8ConnectedSSID[0]), (u8ConnectedSSID[1]), (u8ConnectedSSID[2]), (u8ConnectedSSID[3]), (u8ConnectedSSID[4]), (u8ConnectedSSID[5])); + PRINT_D(GENERIC_DBG, "save Bssid = %pM\n", pstrHostIFconnectAttr->pu8bssid); + PRINT_D(GENERIC_DBG, "save bssid = %pM\n", u8ConnectedSSID); } s32Error = SendConfigPkt(SET_CFG, strWIDList, u32WidsCount, false, (u32)pstrWFIDrv); diff --git a/drivers/staging/wilc1000/linux_mon.c b/drivers/staging/wilc1000/linux_mon.c index f5296f5..c039898 100644 --- a/drivers/staging/wilc1000/linux_mon.c +++ b/drivers/staging/wilc1000/linux_mon.c @@ -336,7 +336,7 @@ static netdev_tx_t WILC_WFI_mon_xmit(struct sk_buff *skb, skb_pull(skb, rtap_len); if (skb->data[0] == 0xc0) - PRINT_INFO(HOSTAPD_DBG, "%x:%x:%x:%x:%x%x\n", skb->data[4], skb->data[5], skb->data[6], skb->data[7], skb->data[8], skb->data[9]); + PRINT_INFO(HOSTAPD_DBG, "%pM\n", skb->data[4]); if (skb->data[0] == 0xc0 && (!(memcmp(broadcast, &skb->data[4], 6 { skb2 = dev_alloc_skb(skb->len + sizeof(struct wilc_wfi_radiotap_cb_hdr)); diff --git a/drivers/staging/wilc1000/linux_wlan.c b/drivers/staging/wilc1000/linux_wlan.c index b352c50..b65e0ae 100644 --- a/drivers/staging/wilc1000/linux_wlan.c +++ b/drivers/staging/wilc1000/linux_wlan.c @@ -2071,8 +2071,7 @@ int mac_open(struct net_device *ndev) Set_machw_change_vir_if(false); host_int_get_MacAddress(priv->hWILCWFIDrv, mac_add); - PRINT_D(INIT_DBG, "Mac address: %x:%x:%x:%x:%x:%x\n", mac_add[0], mac_add[1], mac_add[2], - mac_add[3], mac_add[4], mac_add[5]); + PRINT_D(INIT_DBG, "Mac address: %pM\n", mac_add); /* loop through the NUM of supported devices and set the MAC address */ for (i = 0; i < g_linux_wlan->u8NoIfcs; i++) { -- 2.5.0 ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: [PATCH 2/3] staging/rtl8723au: Use %pM format specifier to print mac address
Alexander Kuleshov writes: > printk() supports %pM format specifier for printing 6-byte MAC/FDDI > addresses in hex notation small buffers, let's use it intead of %x:%x... > > Signed-off-by: Alexander Kuleshov > --- > drivers/staging/rtl8723au/core/rtw_mlme_ext.c | 7 ++- > 1 file changed, 2 insertions(+), 5 deletions(-) Works for me Acked-by: Jes Sorensen ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
[PATCH] staging: panel: panel.c: Fixed coding style issues
From: Nayeemahmed Badebade Fixed warnings reported by checkpatch.pl: - Block comments use a trailing */ on a separate line - Block comments use * on subsequent lines Signed-off-by: Nayeemahmed Badebade --- drivers/staging/panel/panel.c | 63 --- 1 file changed, 42 insertions(+), 21 deletions(-) diff --git a/drivers/staging/panel/panel.c b/drivers/staging/panel/panel.c index 3e9ee7e..498d623 100644 --- a/drivers/staging/panel/panel.c +++ b/drivers/staging/panel/panel.c @@ -909,8 +909,10 @@ static void lcd_gotoxy(void) { lcd_write_cmd(LCD_CMD_SET_DDRAM_ADDR | (lcd.addr.y ? lcd.hwidth : 0) - /* we force the cursor to stay at the end of the -line if it wants to go farther */ + /* + * we force the cursor to stay at the end of the + * line if it wants to go farther + */ | ((lcd.addr.x < lcd.bwidth) ? lcd.addr.x & (lcd.hwidth - 1) : lcd.bwidth - 1)); } @@ -1294,8 +1296,10 @@ static inline int handle_lcd_special_code(void) if (lcd.flags & (LCD_FLAG_L)) lcd_backlight(1); else if (lcd.light_tempo == 0) - /* switch off the light only when the tempo - lighting is gone */ + /* +* switch off the light only when the tempo +* lighting is gone +*/ lcd_backlight(0); } } @@ -1323,8 +1327,10 @@ static void lcd_write_char(char c) case '\b': /* go back one char and clear it */ if (lcd.addr.x > 0) { - /* check if we're not at the - end of the line */ + /* +* check if we're not at the +* end of the line +*/ if (lcd.addr.x < lcd.bwidth) /* back one char */ lcd_write_cmd(LCD_CMD_SHIFT); @@ -1340,8 +1346,10 @@ static void lcd_write_char(char c) lcd_clear_fast(); break; case '\n': - /* flush the remainder of the current line and - go to the beginning of the next line */ + /* +* flush the remainder of the current line and +* go to the beginning of the next line +*/ for (; lcd.addr.x < lcd.bwidth; lcd.addr.x++) lcd_write_data(' '); lcd.addr.x = 0; @@ -1364,8 +1372,10 @@ static void lcd_write_char(char c) } } - /* now we'll see if we're in an escape mode and if the current - escape sequence can be understood. */ + /* +* now we'll see if we're in an escape mode and if the current +* escape sequence can be understood. +*/ if (lcd.esc_seq.len >= 2) { int processed = 0; @@ -1388,8 +1398,10 @@ static void lcd_write_char(char c) } /* LCD special escape codes */ - /* flush the escape sequence if it's been processed - or if it is getting too long. */ + /* +* flush the escape sequence if it's been processed +* or if it is getting too long. +*/ if (processed || (lcd.esc_seq.len >= LCD_ESCAPE_LEN)) lcd.esc_seq.len = -1; } /* escape codes */ @@ -1403,8 +1415,10 @@ static ssize_t lcd_write(struct file *file, for (; count-- > 0; (*ppos)++, tmp++) { if (!in_interrupt() && (((count + 1) & 0x1f) == 0)) - /* let's be a little nice with other processes - that need some CPU */ + /* +* let's be a little nice with other processes +* that need some CPU +*/ schedule(); if (get_user(c, tmp)) @@ -1459,8 +1473,10 @@ static void panel_lcd_print(const char *s) if (lcd.enabled && lcd.initialized) { for (; count-- > 0; tmp++) { if (!in_interrupt() && (((count + 1) & 0x1f) == 0)) - /* let's be a little nice with other processes - that need some CPU */ +
Re: [PATCH] staging: panel: panel.c: Fixed coding style issues
On Thu, Aug 27, 2015 at 09:02:46PM +0530, nayeem wrote: > From: Nayeemahmed Badebade > > Fixed warnings reported by checkpatch.pl: > - Block comments use a trailing */ on a separate line > - Block comments use * on subsequent lines > > Signed-off-by: Nayeemahmed Badebade Acked-by: Willy Tarreau Thanks! Willy ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
Re: [PATCH 11/16] staging: rtl8723au: remove unimplemented function declarations
Luca Ceresoli writes: > Signed-off-by: Luca Ceresoli > Cc: Greg Kroah-Hartman > Cc: Jes Sorensen > Cc: Larry Finger > --- > drivers/staging/rtl8723au/include/rtw_cmd.h | 2 -- > 1 file changed, 2 deletions(-) Acked-by: Jes Sorensen ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel