A consistent model for leptogenesis, dark matter and the IceCube signal