Hi Jaganath, On Thu, Jul 05, 2012, Jaganath Kanakkassery wrote: > In case if ssp is failed, user cannot differentiate from the status > whether failure is caused by local rejection or remote rejection > because authentication failure is coming in both the cases. > > This patch overrides the status from controller with "pin or key missing" > in case of local rejection. In legacy pairing already contoller gives > this error. > > This patch will be useful if user can take some action based on local > or remote rejection > > Signed-off-by: Jaganath Kanakkassery <jaganath.k@xxxxxxxxxxx> > --- --snip-- > + /* Override status if local device rejected pairing */ > + if (auth_rejected == true) > + ev.status = MGMT_STATUS_NOT_PAIRED; > + else > + ev.status = mgmt_status(status); You're not returning "pin or key missing" (which sounds like an HCI error) but MGMT_STATUS_NOT_PAIRED. Please be honest about this in your commit message. However, I don't think this is a very intuitive error code for a local rejection. Could you just use MGMT_STATUS_REJECTED for it? I think you'll get "pin or key missing" also if the remote side rejects so I don't think that's a good HCI error to derive the needed mgmt error from. Johan -- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html