struct Crypto1State* lfsr_recovery64(uint32_t ks2, uint32_t ks3);
uint32_t *lfsr_prefix_ks(uint8_t ks[8], int isodd);
struct Crypto1State*
-lfsr_common_prefix(uint32_t pfx, uint32_t rr, uint8_t ks[8], uint8_t par[8][8]);
+lfsr_common_prefix(uint32_t pfx, uint32_t rr, uint8_t ks[8], uint8_t par[8][8], uint8_t no_par);
void lfsr_rollback_bit(struct Crypto1State* s, uint32_t in, int fb);
return x;
#endif
}
+
+#if !defined LOWMEM && defined __GNUC__
+extern uint8_t filterlut[1 << 20];
+#define filter(x) (filterlut[(x) & 0xfffff])
+#define filter_unsafe(x) (filterlut[x])
+#else
static inline int filter(uint32_t const x)
{
uint32_t f;
f |= 0x0d938 >> (x >> 16 & 0xf) & 1;
return BIT(0xEC57E80A, f);
}
+#define filter_unsafe(x) (filter(x))
+#endif
+
#ifdef __cplusplus
}
#endif