[ATM]: atm_pcr_goal() doesn't modify its argument's contents -- mark it as const

Signed-off-by: Mitchell Blank Jr <mitch@sfgoth.com>
Signed-off-by: Chas Williams <chas@cmf.nrl.navy.mil>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by Mitchell Blank Jr and committed by David S. Miller c219750b c9933d08

+8 -5
+1 -1
include/linux/atmdev.h
··· 468 468 int atm_charge(struct atm_vcc *vcc,int truesize); 469 469 struct sk_buff *atm_alloc_charge(struct atm_vcc *vcc,int pdu_size, 470 470 gfp_t gfp_flags); 471 - int atm_pcr_goal(struct atm_trafprm *tp); 471 + int atm_pcr_goal(const struct atm_trafprm *tp); 472 472 473 473 void vcc_release_async(struct atm_vcc *vcc, int reply); 474 474
+7 -4
net/atm/atm_misc.c
··· 74 74 */ 75 75 76 76 77 - int atm_pcr_goal(struct atm_trafprm *tp) 77 + int atm_pcr_goal(const struct atm_trafprm *tp) 78 78 { 79 - if (tp->pcr && tp->pcr != ATM_MAX_PCR) return -tp->pcr; 80 - if (tp->min_pcr && !tp->pcr) return tp->min_pcr; 81 - if (tp->max_pcr != ATM_MAX_PCR) return -tp->max_pcr; 79 + if (tp->pcr && tp->pcr != ATM_MAX_PCR) 80 + return -tp->pcr; 81 + if (tp->min_pcr && !tp->pcr) 82 + return tp->min_pcr; 83 + if (tp->max_pcr != ATM_MAX_PCR) 84 + return -tp->max_pcr; 82 85 return 0; 83 86 } 84 87